add changes procurement
This commit is contained in:
@@ -26,7 +26,7 @@ class ProcurementSearch extends Procurement
|
||||
{
|
||||
return [
|
||||
[[ 'id_warehouse', 'id_user', 'id_product', ], 'integer'],
|
||||
[[ 'date_start', ], 'date' , 'timestampAttribute' => 'timestampStart' ],
|
||||
[[ 'date_start', ], 'date' , 'timestampAttribute' => 'timestampStart' ,'timestampAttributeFormat' => 'yyyy-MM-dd' ],
|
||||
[[ 'date_end' , ], 'date' , 'timestampAttribute' => 'timestampEnd' ,'timestampAttributeFormat' => 'yyyy-MM-dd' ],
|
||||
];
|
||||
}
|
||||
@@ -63,6 +63,14 @@ class ProcurementSearch extends Procurement
|
||||
return $dataProvider;
|
||||
}
|
||||
|
||||
|
||||
if ( empty($this->date_start) ){
|
||||
$this->timestampStart = '';
|
||||
}
|
||||
if ( empty($this->date_end) ){
|
||||
$this->timestampEnd = '';
|
||||
}
|
||||
|
||||
$query->andFilterWhere([
|
||||
'id_warehouse' => $this->id_warehouse,
|
||||
'id_user' => $this->id_user,
|
||||
|
||||
Reference in New Issue
Block a user