afa 6 月之前
父節點
當前提交
0dcf612369
共有 1 個文件被更改,包括 6 次插入0 次删除
  1. 6 0
      application/common/model/AnnouncementType.php

+ 6 - 0
application/common/model/AnnouncementType.php

@@ -38,6 +38,12 @@ class AnnouncementType extends Model
             return $data;
       }
 
+      //获取大分类子分类
+      public static function getSubTypeByPId(int $typeId){
+
+            return self::where('pid', $typeId)->column('id,title');
+      }
+    
 
       public function getCreatetimeTextAttr($value, $data)
       {