- change status to product history status
This commit is contained in:
parent
25a48ff39f
commit
c6d4b12307
|
@ -282,8 +282,9 @@ export class ProductService {
|
|||
'current_price',
|
||||
'current_price.partner_id is NULL and current_price.end_date is NULL',
|
||||
)
|
||||
.leftJoin('product.statusHistory', 'status_history')
|
||||
.where(
|
||||
`product.supplier_id = :supplier_id and product.status = 'ACTIVE'`,
|
||||
`product.supplier_id = :supplier_id and status_history.status = 'ACTIVE'`,
|
||||
{
|
||||
supplier_id: supplier,
|
||||
},
|
||||
|
@ -451,7 +452,6 @@ export class ProductService {
|
|||
relations: ['supplier'],
|
||||
where: {
|
||||
code: code,
|
||||
status: 'ACTIVE',
|
||||
},
|
||||
});
|
||||
} catch (e) {
|
||||
|
|
Loading…
Reference in New Issue
Block a user