|
|
|
|
|
|
|
|
$paramsSearch['id_user'] = $params['id_user']; |
|
|
$paramsSearch['id_user'] = $params['id_user']; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
$query = Order::searchQuery($paramsSearch, [ |
|
|
|
|
|
|
|
|
$optionsArray = [ |
|
|
'orderby' => isset($params['order_by']) ? $params['order_by'] : 'distribution.date DESC', |
|
|
'orderby' => isset($params['order_by']) ? $params['order_by'] : 'distribution.date DESC', |
|
|
'ignore_id_producer' => isset($options['ignore_id_producer']) ? $options['ignore_id_producer'] : false |
|
|
|
|
|
]); |
|
|
|
|
|
|
|
|
]; |
|
|
|
|
|
if(isset($options['ignore_id_producer']) && $options['ignore_id_producer']) { |
|
|
|
|
|
$optionsArray['ignore_id_producer'] = true; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
$query = Order::searchQuery($paramsSearch, $optionsArray); |
|
|
|
|
|
|
|
|
$dataProvider = new ActiveDataProvider([ |
|
|
$dataProvider = new ActiveDataProvider([ |
|
|
'query' => $query, |
|
|
'query' => $query, |