change cart to plain post from ajax
This commit is contained in:
@@ -60,16 +60,24 @@ class ProductSearch extends Product
|
||||
// $query->where('0=1');
|
||||
return $dataProvider;
|
||||
}
|
||||
|
||||
if ( !empty($this->barcode)){
|
||||
$this->barcode = strtolower($this->barcode);
|
||||
}
|
||||
|
||||
if ( !empty($this->product_number)){
|
||||
$this->product_number = strtolower($this->product_number);
|
||||
}
|
||||
|
||||
$query->andFilterWhere([
|
||||
'product.id_product_category' => $this->id_product_category,
|
||||
'product.id_account' => $this->id_account,
|
||||
'product.status' => $this->status,
|
||||
'lower(product.product_number)' => $this->product_number,
|
||||
'lower(product.barcode)' => $this->barcode,
|
||||
]);
|
||||
|
||||
$query->andFilterWhere(['like', 'product_number', $this->product_number])
|
||||
->andFilterWhere(['like', 'barcode', $this->barcode])
|
||||
->andFilterWhere(['like', 'name', $this->name]);
|
||||
$query->andFilterWhere(['like', 'name', $this->name]);
|
||||
|
||||
return $dataProvider;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user