Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-60544

Not possible to reset atto autosave from JS

    XMLWordPrintable

    Details

    • Affected Branches:
      MOODLE_32_STABLE, MOODLE_33_STABLE, MOODLE_34_STABLE

      Description

      We have no current way to reset the atto autosave content.
      It is currently cleared from within atto by listenign for a form submit event, but that event is not triggered when you call form.submit() - only when the submit button(s) are cancelled.

      Recommend:

      1. Make a new autosave event
      2. Have existing submit listener trigger the auto save event
      3. Allow anything to call it

      This will allow JS forms to clear autosave.
      May be even better to migrate the autosave component out of atto and allow it to take the relevant params and have events for save, resume, reset, etc. so that it's totally independent of atto.

      Note: This affects assign at the moment.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              Unassigned Unassigned
              Reporter:
              dobedobedoh Andrew Nicols
              Participants:
              Component watchers:
              Adrian Greeve, Jake Dallimore, Mathew May, Mihail Geshoski, Peter Dias, Sujith Haridasan, Adrian Greeve, Jake Dallimore, Mathew May, Mihail Geshoski, Peter Dias, Sujith Haridasan, Andrew Nicols, Jun Pataleta, Michael Hawkins, Shamim Rezaie, Simey Lameze
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Dates

                Created:
                Updated: