Kaynağa Gözat

获取导航栏目的seo

15313670163 2 ay önce
ebeveyn
işleme
c8d4a4fe23

+ 27 - 1
app/JsonRpc/WebsiteService.php

@@ -1451,6 +1451,32 @@ class WebsiteService implements WebsiteServiceInterface
         }
         return Result::success($result);
     }
-    
+    /**
+     * 获取网站栏目seo
+     * @param array $data
+     * @return array
+     */
+    public function getWebsiteCategoryHead(array $data): array
+    {
+        if(isset($data['website_id']) && !empty($data['website_id'])){
+            $website = Website::where('id',$data['website_id'])->where('status',1)->first();
+            if (empty($website)) {
+                return Result::error("找不到网站",0); 
+            }
+        }else{
+            return Result::error("参数错误",0);
+        }
+        if (isset($data['catid']) && !empty($data['catid'])) {
+            $fcatid = WebsiteCategory::where('website_id',$data['website_id'])->where('category_id',$data['catid'])->first();
+            if (empty($fcatid)) {
+                return Result::error("导航id错误",0);
+            }
+            $result = Category::where('id',$data['catid'])->first();
+        }
+        if (empty($result)) {
+            return Result::error("暂无导航",0);
+        }
+        return Result::success($result);
+    }
     
 }

+ 1 - 0
app/JsonRpc/WebsiteServiceInterface.php

@@ -88,4 +88,5 @@ interface WebsiteServiceInterface
     public function getWebsiteFooterCategoryList(array $data): array;
     public function getWebsiteFooterCategoryInfo(array $data): array;
     public function selectWebsiteCategory(array $data): array;
+    public function getWebsiteCategoryHead(array $data): array;
 }

Dosya farkı çok büyük olduğundan ihmal edildi
+ 0 - 0
runtime/container/scan.cache


Bu fark içinde çok fazla dosya değişikliği olduğu için bazı dosyalar gösterilmiyor