• If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Announcement

Collapse
No announcement yet.

Issue with Resetting a field in a form that is overridden to be considered changed

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Issue with Resetting a field in a form that is overridden to be considered changed

    I have a form with one field where users will put in their clock number. Once their number is input, and the override to consider having been changed triggers, it displays the rest of the fields on the form for them to log in with. If the user is already logged in somewhere else, then it will automatically go to the next page once the same override has triggered.

    My issue arises whenever a user logs out. when they click the log out button, it shows the clock number log in widget and clears/resets all fields, but until they deselect and reselect the field for inserting their clock number, the override for considering it to have been changed seems to stop working. This means if someone logs out and then someone tries to log in after, putting in their clock number does nothing.

    Any ideas on a way to fix this?

  • #2
    Does the reset/clear all fields cause the clock number to be blank?

    Comment


    • #3
      Yes, it does. After changing some code around I was able to make it a little more lenient, but it still fails to trigger if someone logs out and then puts the same clock number in again.

      Comment


      • #4
        This is a known bug and already has a fix in the next upcoming update. For now, try this:
        • Give your form a friendly name...suppose you call it "loginForm"
          • You can give it a name when you click the settings icon when you hover over the form
        • In addition to your action where you reset the form...add a new action "Execute Script". Enter the following code
        Code:
        const loginForm = getWidget('loginForm');
        loginForm.down('[name=MY_FIELD_NAME]').previousVal = null;
        success();
        Replace MY_FIELD_NAME with the name of your field...exactly as it spelled in your form widget (case matters).

        Comment

        Working...
        X