update
This commit is contained in:
parent
e42ffe94c6
commit
71fca81585
@ -40,7 +40,6 @@ class CostProjectLists extends BaseAdminDataLists implements ListsSearchInterfac
|
||||
return [
|
||||
'=' => ['cost_project_id'],
|
||||
'%like%' => ['superior_sort', 'name'],
|
||||
'between_time'=>['create_time']
|
||||
];
|
||||
}
|
||||
|
||||
@ -56,7 +55,13 @@ class CostProjectLists extends BaseAdminDataLists implements ListsSearchInterfac
|
||||
*/
|
||||
public function lists(): array
|
||||
{
|
||||
$startTime = $this->request->param('start_time', '');
|
||||
$endTime = $this->request->param('end_time', '');
|
||||
return CostProject::where($this->searchWhere)
|
||||
->where(function ($query) use($startTime, $endTime) {
|
||||
if ($startTime && $endTime) {
|
||||
$query->whereTime('create_time', [$startTime, $endTime]);
|
||||
}})
|
||||
->field(['id', 'project_num', 'project_name', 'contract_id', 'types', 'industry', 'province', 'city', 'address', 'starting', 'endtime', 'jhgq', 'depar', 'principal', 'person', 'invest', 'budget', 'cost', 'approval', 'aunit', 'Acontact', 'acontactnum', 'date', 'generalize', 'note', 'remark', 'annex'])
|
||||
->limit($this->limitOffset, $this->limitLength)
|
||||
->with(['contract'])
|
||||
|
Loading…
x
Reference in New Issue
Block a user