ets-berkeley-edu/calcentral — pull request #2793 by redconfetti (2014-08-13 18:52:20+00:00)
Title: [QA] CLC-4000 - Applying event to 'Start Over' button in addition to '+ People' button

[QA Fix] https://jira.ets.berkeley.edu/jira/browse/CLC-4000

Fixes bug with the Javascript modification to the 'Add People' popup window in Canvas. After the user submits the form, if there is an error, they can click on a 'Start Over' button which reloads the 'Add People' form view. This form view is refreshed to the original default content, not the modified content applied by our Javascript customization.

This updates the script to continually poll every 300 milliseconds for a 'Start Over' button that has not had the click event applied to it which modifies the help text. This is necessary because the 'Start Over' button is removed and added to the DOM dynamically, meaning new versions without the event applied are shown. Now they are caught and event is re-applied.