Broadleaf Microservices
  • v1.0.0-latest-prod

Mark Quote as Expired

Overview

A scheduled job can be configured to routinely mark expired quotes as EXPIRED status based on defined expiration date.

Configuration

The MarkQuotesExpiredJobListener listens for MARK_QUOTE_TO_EXPIRED events, then parses the job details to get a list of statuses to exclude from the job. If a parameter is not found in the job details, a list of default statuses will be used:

  • DRAFTING

  • EXPIRED

  • REJECTED

  • CANCELED

  • QUOTE_REQUESTED

Job Details

Job Detail Key Type Default Value Description

statusesToExclude

Comma-separated set

DRAFTING,EXPIRED,REJECTED,CANCELED,QUOTE_REQUESTED

Set of quote statuses to exclude

Example ScheduledJobs service insert

The following sql snippet would configure a job to run every minute to mark quotes to EXPIRED based on their expiration date and configured statuses to exclude.

-- mark quotes as expired scheduled job
INSERT INTO BLC_SCHEDULED_JOB (ID, CRON, ENABLED, EXECUTED, MANAGE_IN_ADMIN, NAME,
                               TIMING_TYPE, TRK_ARCHIVED, TRK_CHANGE_DETAILS, TRK_TENANT_ID, TYPE)
VALUES ('markQuoteToExpiredId', '0 */1 * ? * *', 'Y', 'N', 'Y',
        'Mark Quotes As Expired', 'CRON', 'N', '[]', '5DF1363059675161A85F576D', 'MARK_QUOTE_TO_EXPIRED');
INSERT INTO BLC_SCHEDULED_JOB_DETAIL (JOB_ID, NAME, VALUE, VALUE_SHA, DETAILS_ORDER)
VALUES ('markQuoteToExpiredId', 'statusesToExclude', 'DRAFTING,EXPIRED,REJECTED,CANCELED,QUOTE_REQUESTED',
        '356a192b7913b04c54574d18c28d46e6395428ab', 0)