作者 lyh

gx

@@ -31,7 +31,7 @@ class RenewProjectController extends BaseController @@ -31,7 +31,7 @@ class RenewProjectController extends BaseController
31 $yesterday = Carbon::yesterday()->toDateString(); 31 $yesterday = Carbon::yesterday()->toDateString();
32 $count_list = $count->list(['date'=>$yesterday,'service_day'=>['<=',15]],'id',['project_id']); 32 $count_list = $count->list(['date'=>$yesterday,'service_day'=>['<=',15]],'id',['project_id']);
33 $arr = []; 33 $arr = [];
34 - foreach ($count_list as $k => $v){ 34 + foreach ($count_list as $v){
35 $arr[] = $v['project_id']; 35 $arr[] = $v['project_id'];
36 } 36 }
37 $sort = ['id' => 'desc']; 37 $sort = ['id' => 'desc'];
@@ -57,6 +57,9 @@ class RenewProjectController extends BaseController @@ -57,6 +57,9 @@ class RenewProjectController extends BaseController
57 * @time :2023/8/11 17:28 57 * @time :2023/8/11 17:28
58 */ 58 */
59 public function renewLists(RenewLogic $logic){ 59 public function renewLists(RenewLogic $logic){
  60 + if(isset($this->map['company']) && !empty($this->map['company'])){
  61 + $this->map['company'] = ['like','%'.$this->map['company'].'%'];
  62 + }
60 $lists = $logic->renewListsLog($this->map,$this->page,$this->row,$this->order); 63 $lists = $logic->renewListsLog($this->map,$this->page,$this->row,$this->order);
61 $this->response('success',Code::SUCCESS,$lists); 64 $this->response('success',Code::SUCCESS,$lists);
62 } 65 }
@@ -30,6 +30,12 @@ class RenewLogic extends BaseLogic @@ -30,6 +30,12 @@ class RenewLogic extends BaseLogic
30 */ 30 */
31 public function renewListsLog($map,$page,$row,$order,$field = ['*']){ 31 public function renewListsLog($map,$page,$row,$order,$field = ['*']){
32 $lists = $this->model->lists($map,$page,$row,$order,$field); 32 $lists = $this->model->lists($map,$page,$row,$order,$field);
  33 + if(!empty($lists['list'])){
  34 + foreach ($lists['list'] as $k => $v){
  35 + $v['plan'] = Project::planMap()[$v['plan']];
  36 + $lists['list'][$k] = $v;
  37 + }
  38 + }
33 return $this->success($lists); 39 return $this->success($lists);
34 } 40 }
35 } 41 }