Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  • Expression: The logical condition that must be met for the validation to fail.

  • Message: The error message displayed to the user when the validation fails.

FailsWhenExpression.mov

Calculation Expression:

The purpose of the calculation expression is to automatically calculate values without requiring any manual effort.

Example Scenario:

Consider a scenario where a doctor wants to calculate a patient's BMI using their height and weight as inputs. Typically, the doctor would need to perform the mathematical calculation manually each time, increasing their workload. It would be more efficient if the doctor could simply enter the patient's height and weight, and the patient's BMI would be automatically calculated and displayed in the BMI field.

Code Example
Code Block
languagejson
"calculate": {
    "calculateExpression": "calcBSA('height', 'weight')"
}

Calculate BMI.mov

Body Surface Area (BSA) Calculation:

This function takes the height and weight values and returns the Body Surface Area (BSA).

Example Scenario:

Consider a scenario where a doctor needs to determine a patient's Body Surface Area (BSA) for medical dosing or treatment plans. By inputting the patient's height and weight, the function can automatically calculate and provide the BSA value, reducing the need for manual calculation and ensuring precision.

Code Example
Code Block
{
  "calculate": {
    "calculateExpression": "calcBSA('height','weight')"
  }
}

Calculate BSA.mov

Expected Date of Delivery (EDD) Calculation:

This function takes the last menstruation date and returns the expected date of delivery (EDD).

Example Scenario:

Consider a scenario where a doctor needs to determine the expected date of delivery (EDD) for a pregnant patient. By inputting the patient's last menstruation date, the function can automatically calculate and provide the EDD, eliminating the need for manual calculation and ensuring accuracy.

Code Example
Code Block
languagejson
{
  "calculate": {
    "calculateExpression": "calcEDD('LMP')"
  }
}

...

Field Validation with Regular Expressions:

This helper allows users to validate fields against regular expressions.

...