Merge branch 'development' into 'devops-production'
add: order by in product retail See merge request empatnusabangsa/ppob/ppob-backend!141
This commit is contained in:
commit
4cb570b3e6
|
@ -263,9 +263,8 @@ export class ProductService {
|
||||||
)
|
)
|
||||||
.select(['product.id'])
|
.select(['product.id'])
|
||||||
.addSelect(['product.name', 'product.code', 'sub_categories.name'])
|
.addSelect(['product.name', 'product.code', 'sub_categories.name'])
|
||||||
.addSelect(
|
.addSelect('(current_price.price + current_price.mark_up_price) as price')
|
||||||
'(current_price.price + current_price.mark_up_price) as price',
|
.orderBy('price', 'ASC');
|
||||||
);
|
|
||||||
|
|
||||||
if (subCategories != 'null' && subCategories) {
|
if (subCategories != 'null' && subCategories) {
|
||||||
baseQuery.andWhere('product.sub_categories_id = :id', {
|
baseQuery.andWhere('product.sub_categories_id = :id', {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user