Merge branch 'devops-staging' of https://gitlab.com/empatnusabangsa/ppob/ppob-backend
This commit is contained in:
commit
b4a00ab365
|
@ -215,7 +215,8 @@ export class ProductService {
|
||||||
.addSelect(
|
.addSelect(
|
||||||
'(current_price.price + current_price.mark_up_price) as mark_up_price',
|
'(current_price.price + current_price.mark_up_price) as mark_up_price',
|
||||||
)
|
)
|
||||||
.orderBy('product.code');
|
.orderBy('product.code')
|
||||||
|
.distinct();
|
||||||
|
|
||||||
if (subCategories && filterSubCategories.length > 0) {
|
if (subCategories && filterSubCategories.length > 0) {
|
||||||
baseQuery.where('product.sub_categories_id IN (:...subCategoryId)', {
|
baseQuery.where('product.sub_categories_id IN (:...subCategoryId)', {
|
||||||
|
@ -299,7 +300,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('(current_price.price + current_price.mark_up_price) as price')
|
.addSelect('(current_price.price + current_price.mark_up_price) as price')
|
||||||
.orderBy('price', 'ASC');
|
.orderBy('price', 'ASC')
|
||||||
|
.distinct()
|
||||||
|
|
||||||
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