Compare 2 date time picker with current date

Issue #816 resolved
Emmy Grimes created an issue

The issue has: Date Time picker 1: Start Date Date Time picker 2: End Date.

Subtask has: Date Time picker3: Executed Date

When the user creates the issue, how do I create JWT validator in the Create transition that "Start Date" must be at least 15 minutes later than the current time. Same thing, the End Date must be at least 15 minutes later than Start Date.

For subtask, how do i make sure that "Executed Date" already in the range of "Start Date" and "End Date"?

Thx

Comments (2)

  1. Fidel Castro Armario repo owner

    Hi @chaunguyen1997,

    You can implement the 3 validations using "Boolean validator with math, date-time or text-string terms" with the following boolean expressions:

    1. "Start Date" must be at least 15 minutes later than the current time: {sssss} > {00057} + 15 * {MINUTE}

    2. "End Date" must be at least 15 minutes later than "Start Date": {eeeee} < {sssss} + 15 * {MINUTE}

    3. "Executed Date" in the range of "Start Date" and "End Date": {sssss} <= {xxxxx} AND {xxxxx} <= {eeeee}

    replacing sssss with field code for Start Date, eeeee with field code for End Date, and xxxxx with field code for Executed Date.

    Note that the 3 fields should be Date-Time Pickers, i.e., they should also consider the time part.

  2. Fidel Castro Armario repo owner

    I close the issue, please reopen it if you find that provided solution is not satisfactory.

  3. Log in to comment