rule engine and configration and fix booking for custoemr

This commit is contained in:
marshal
2026-06-01 23:15:11 +03:00
parent b9ca0b8a82
commit 452ebdbc0a
52 changed files with 3355 additions and 3358 deletions

View File

@@ -27,9 +27,9 @@ export class WeightLimitRulesRepository implements IWeightLimitRulesRepository {
.createQueryBuilder('rule')
.innerJoinAndSelect('rule.containerType', 'ct')
.where('rule.container_type_id = :containerTypeId', { containerTypeId })
.andWhere('(rule.trade_direction = :dir OR rule.trade_direction = :any)', {
.andWhere('(rule.trade_direction = :dir OR rule.trade_direction = :both)', {
dir: tradeDirection,
any: 'ANY',
both: 'BOTH',
})
.andWhere('rule.effective_from <= :now', { now })
.andWhere('(rule.effective_to IS NULL OR rule.effective_to > :now)', { now })