Skip to content

Commit

Permalink
something in local is ok but in server runnning buggy
Browse files Browse the repository at this point in the history
  • Loading branch information
bahram1249 committed May 26, 2024
1 parent d859808 commit bd5ac72
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,12 @@ export class ProductDiscountSetterService {
break;
}
}

console.log(inventory.id);
if (discountApplied != null) {
console.log(discountApplied);
}

if (discountApplied == null && inventory.discountTypeId != null) {
await this.inventoryRepository.update(
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ export class ProductDiscountProcessor extends WorkerHost {
const listFilter = _.cloneDeep(this.emptyListFilter);
listFilter.limit = 10;
listFilter.offset = 0;
console.log('initial list filter', listFilter);
await this.productDiscountService.fetchAndApplyDiscountTime(listFilter);
return Promise.resolve();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ export class ProductDiscountService {
let more = true;
let page = 1;
while (more) {
console.log('page', page);
const { resultQuery, countQuery } =
await this.productQueryBuilderService.findAllAndCountQuery(
_.merge(filter, { inventoryStatusId: InventoryStatusEnum.available }),
Expand Down

0 comments on commit bd5ac72

Please sign in to comment.