WIN-2308041133\Administrator 1 hafta önce
ebeveyn
işleme
8ae7c127bd
1 değiştirilmiş dosya ile 6 ekleme ve 3 silme
  1. 6 3
      app/api/controller/Education.php

+ 6 - 3
app/api/controller/Education.php

@@ -232,10 +232,13 @@ class Education
         if($totalCount>0){
         if($totalCount>0){
             $data = (new ContractTemplateModel)
             $data = (new ContractTemplateModel)
                 ->where($where)
                 ->where($where)
-                ->order("id", "desc")
-                ->page($post["page"], $post["pageSize"])
-                ->select();
+//                ->order("id", "desc")
+//                ->page($post["page"], $post["pageSize"])
+                ->find();
 //            $data['id'] = $oData['id'];
 //            $data['id'] = $oData['id'];
+            if (empty($data)){
+                return app('json')->fail("模版号不存在");
+            }
             $data['imgs'] = getImageAr($data["imgs"]);
             $data['imgs'] = getImageAr($data["imgs"]);
 
 
             $data['content'] = json_decode($data['content']);
             $data['content'] = json_decode($data['content']);