Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

LEAF 4169 IFTHEN - new controllers and operators #2273

Merged

Conversation

aerinkayne
Copy link
Contributor

Adds number and currency to available controller questions.

Adds comparison options:

  • greater than
  • greater than or equal
  • less than
  • less than or equal

These options are available if the controller format is number or currency, or if other controllers include number in their options. A number type input field will appear if one of these operators is chosen.

Adjusts save/remove behavior:
Modal now has an explicit close button and does not automatically close on save/remove.

Other updates:
Changed data structures for some longer arrays and simplified setup.

Testing / Impact

Condition Entry

Confirm app loads as expected and conditions can be added, removed and edited as expected.
Changes made to the form should be immediately reflected in the ifthen app without needing to reload the page. If there are multiple conditions on a question, toggling between list items should not cause any unexpected behaviors.

Form Entry

Ensure that new and prior controller comparisons behave as expected.

Use some instead of every for operator trigger.
Filter out NaN values and handle some edge cases.
Add vue side code and rebuild
Adjust close and toolip behavior, simplify some logic.
Update operator selection.  Improve choicesJS triggers.
Initial add number and currency parent controls.
Update endpoint for form indicators get and simplify
condition setup logic.  Fix issue with modal scrolling
@aerinkayne aerinkayne self-assigned this Jan 16, 2024
Copy link
Collaborator

@Pelentan Pelentan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My comment about pulling that bit of code out is for thought, not action at this time.

@@ -224,13 +242,23 @@ export default {
getOperatorText(condition = {}) {
const parFormat = condition.parentFormat.toLowerCase();
let text = condition.selectedOp;
switch(text) {

const op = condition.selectedOp;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This bit gets repeated a lot. We might want to look at pulling it out into into a class/function that can be used by everything that needs it.

@Pelentan Pelentan added the With QA Ticket is to QA. No changes unless pulled back to in progress label Feb 1, 2024
@Pelentan Pelentan changed the base branch from master to rc/2024-01-31/Sprint-67-c2 February 1, 2024 20:32
@Pelentan Pelentan marked this pull request as ready for review February 1, 2024 20:32
@Pelentan Pelentan merged commit 8dae01b into rc/2024-01-31/Sprint-67-c2 Feb 1, 2024
5 of 10 checks passed
@aerinkayne aerinkayne deleted the feature/LEAF-4169/ifthen_greaterless_new branch August 6, 2024 15:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
With QA Ticket is to QA. No changes unless pulled back to in progress
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants