Fix Detsta Import -> Transfer type cash , when unsuccessful
This commit is contained in:
@@ -45,10 +45,11 @@ class InventoryConsoleController extends Controller{
|
||||
$query->innerJoin('product','sale.id_product = product.id_product');
|
||||
|
||||
$query->andWhere(['transfer.type' => Transfer::TYPE_PRODUCT]);
|
||||
$query->andWhere(['in', 'transfer.type', [Transfer::STATUS_NOT_PAID, Transfer::STATUS_PAID]]);
|
||||
$query->andWhere(['in', 'transfer.status', [Transfer::STATUS_NOT_PAID, Transfer::STATUS_PAID]]);
|
||||
$query->andWhere(['product.id_product' => $prev->id_product]);
|
||||
|
||||
$query->andWhere([ '>','transfer.created_at',$start ]);
|
||||
$query->andWhere([ '<','transfer.created_at',$end ]);
|
||||
|
||||
$products = $query->scalar();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user