Pārlūkot izejas kodu

全流程巡检接口

任敬轩 2 dienas atpakaļ
vecāks
revīzija
78f98321d6

+ 1 - 4
Modules/Admin/Http/Controllers/Api/ApiController.php

@@ -84,11 +84,8 @@ class ApiController extends BaseController
         $result['data']   = [];
 
         $depart = Input::get('depart', '');
-        if (!$depart) {
-            return self::errorResponse(ApiEnum::STATUS_CODE_EMPTY);
-        }
 
-        $result['data'] = DB::connection('mysql_fwe10')->table('uf_zhxx_qlczgry')->where('dwmc',$depart)->where('is_delete',0)->pluck('zgrxm');
+        $result['data'] = DB::connection('mysql_fwe10')->table('uf_zhxx_qlczgry')->where('dwmc','like','%'.$depart.'%')->where('is_delete',0)->pluck('zgrxm');
 
         return $result;
     }