소스 검색

网站排序

rkljw 1 개월 전
부모
커밋
e993b104c0
3개의 변경된 파일25개의 추가작업 그리고 0개의 파일을 삭제
  1. 19 0
      app/JsonRpc/WebsiteService.php
  2. 6 0
      app/JsonRpc/WebsiteServiceInterface.php
  3. 0 0
      runtime/container/scan.cache

+ 19 - 0
app/JsonRpc/WebsiteService.php

@@ -2430,4 +2430,23 @@ class WebsiteService implements WebsiteServiceInterface
         }
     }
 
+    /**
+     * 修改网站栏目排序
+     * @param array $data
+     * @return array
+     */
+    public function upWebsiteCategorySort(array $data): array
+    {
+        $where = [
+            'website_id' => $data['website_id'],
+            'id' => $data['id'],
+        ];
+        $result = WebsiteCategory::where($where)->update($data);
+        if ($result) {
+            return Result::success($result);
+        } else {
+            return Result::error("更新失败", 0);
+        }
+    }
+
 }

+ 6 - 0
app/JsonRpc/WebsiteServiceInterface.php

@@ -109,4 +109,10 @@ interface WebsiteServiceInterface
      */
     public function getAllCategory(array $data): array;
 
+    /**
+     * 修改网站栏目排序
+     * @param array $data
+     * @return array
+     */
+    public function upWebsiteCategorySort(array $data): array;
 }

파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
+ 0 - 0
runtime/container/scan.cache


이 변경점에서 너무 많은 파일들이 변경되어 몇몇 파일들은 표시되지 않았습니다.