update
This commit is contained in:
parent
8e64219988
commit
98de7b1676
@ -40,8 +40,8 @@ class CostProjectLists extends BaseAdminDataLists implements ListsSearchInterfac
|
|||||||
public function setSearch(): array
|
public function setSearch(): array
|
||||||
{
|
{
|
||||||
return [
|
return [
|
||||||
'=' => ['cost_project_id'],
|
'=' => ['cost_project_id','types','industry'],
|
||||||
'%like%' => ['superior_sort', 'name'],
|
'%like%' => ['project_num', 'project_name'],
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -17,6 +17,7 @@ namespace app\adminapi\lists\task;
|
|||||||
|
|
||||||
use app\adminapi\lists\BaseAdminDataLists;
|
use app\adminapi\lists\BaseAdminDataLists;
|
||||||
use app\common\lists\ListsExcelInterface;
|
use app\common\lists\ListsExcelInterface;
|
||||||
|
use app\common\model\cost_project\CostProject;
|
||||||
use app\common\model\task\TaskType;
|
use app\common\model\task\TaskType;
|
||||||
use app\common\lists\ListsSearchInterface;
|
use app\common\lists\ListsSearchInterface;
|
||||||
|
|
||||||
@ -65,7 +66,10 @@ class TaskTypeLists extends BaseAdminDataLists implements ListsSearchInterface,L
|
|||||||
}})
|
}})
|
||||||
->limit($this->limitOffset, $this->limitLength)
|
->limit($this->limitOffset, $this->limitLength)
|
||||||
->order(['id' => 'desc'])
|
->order(['id' => 'desc'])
|
||||||
->select()
|
->select()->each(function($data){
|
||||||
|
$project = CostProject::field('project_name')->where('id',$data['cost_project_id'])->findOrEmpty();
|
||||||
|
$data['project_name'] = $project['project_name'];
|
||||||
|
})
|
||||||
->toArray();
|
->toArray();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user