diff --git a/modules/monitor/back/methods/sales-monitor/salesFilter.js b/modules/monitor/back/methods/sales-monitor/salesFilter.js index 881fc637a..32d8d3a6a 100644 --- a/modules/monitor/back/methods/sales-monitor/salesFilter.js +++ b/modules/monitor/back/methods/sales-monitor/salesFilter.js @@ -352,20 +352,37 @@ module.exports = Self => { return {'t.alertLevel': value}; case 'pending': if (value) { - return {and: [ - {'t.alertLevel': 0}, - {'t.alertLevelCode': {nin: [ - 'OK', - 'BOARDING', - 'PRINTED', - 'PRINTED_AUTO', - 'PICKER_DESIGNED' - ]}} - ]}; + return {'t.alertLevelCode': {inq: [ + 'FIXING', + 'FREE', + 'NOT_READY', + 'BLOCKED', + 'EXPANDABLE', + 'CHAINED', + 'WAITING_FOR_PAYMENT' + ]}}; } else { - return {and: [ - {'t.alertLevel': {gt: 0}} - ]}; + return {'t.alertLevelCode': {inq: [ + 'ON_PREPARATION', + 'ON_CHECKING', + 'CHECKED', + 'PACKING', + 'PACKED', + 'INVOICED', + 'ON_DELIVERY', + 'PREPARED', + 'WAITING_FOR_PICKUP', + 'DELIVERED', + 'PRINTED_BACK', + 'LAST_CALL', + 'PREVIOUS_PREPARATION', + 'ASSISTED_PREPARATION', + 'BOARD', + 'PRINTED STOWAWAY', + 'OK STOWAWAY', + 'HALF_PACKED', + 'COOLER_PREPARATION' + ]}}; } case 'agencyModeFk': case 'warehouseFk':