Solution for Updating the Display Value of a Select List Based on another Select List

Context: Using Quickbooks pack, I pulled in information about my Accounts and Sub Accounts that a user will have to select. The options for the sub-account list is dependent on what the user selected from the primary/parent account.

Problem: If the user changes the parent account, while the options for the sub-account changes, the DISPLAY will not update. This can cause problems if that value is needed elsewhere.

Solution: I added an additional column that will output the parent account of the sub account selected by the user. I then created a condition/checkbox for when the parent account (of the selected sub account) does not match the primary account. A button will become activated when the condition is false. When the button is pushed it essentially resets the sub account DISPLAY value. I’ve also create a push button that will push all these individual buttons that need to be update.

(Note: I would like to disable this push button for when there are not updates needed but I can seem to get the right syntax)
So here are some screen shots of this setup

  1. Primary accounts are already selected. Notice the second column of available sub accounts to select based on the primary account selected.

  2. In the 3rd column, I selected my sub account from the options in column 2. Notice in column 4, the parent account is populated from the sub account selected. If this value matches with the 1st column, I don’t need to update my sub account, so the button column is disabled.

  3. In this screenshot, I changed the values in column 1, which updated the sub accounts available. Notice that the 3rd column did not change the display value to reflect the change in the 1st column/primary account. Also, the 4th column now does not match the 1st column and the column button become active.

  4. In this shot, I clicked on the column button of the first row to update the display value of the 3rd column and the associated 4th column, which is the parent account of the selected sub account.

  5. In this last shot, I pressed the push button (outside the table) that pushed all the active column buttons. Notice how the display value of the 3rd column was updated
    .

What I envision is using a webhook that will automatically detect and update this mismatch between column 1 and column 4.

Thoughts?