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

Improve placement of User Tours' Reset tour on page link

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 3.3, 3.4
    • Fix Version/s: 3.4
    • Component/s: User Tours
    • Testing Instructions:
      Hide

      Note There should be no change to functionality or appearance.

      1. As admin on a new site visit the front page (Site Home). The Boost - Administrator user tour should start (standard behaviour).
      2. End the tour.
        1. Confirm the 'Reset user tour on this page' link appears in the footer area (standard behaviour).
      3. Edit the admin/tool/usertours/templates/resettour.mustache template and add the following:

        {{#js}}
        alert("JS Was executed");
        {{/js}}
        

      4. Refresh the Site Home page
        1. Confirm that the alert was shown
      5. Edit the columns2 template for your current theme and copy/paste the following to an additional place in the file:

        <div class="tool_usertours-resettourcontainer"></div>
        

      6. Refresh the Site Home page
        1. Confirm that the Reset link appears both in the footer (standard behaviour), and wherever you just added it
      Show
      Note There should be no change to functionality or appearance. As admin on a new site visit the front page (Site Home). The Boost - Administrator user tour should start (standard behaviour). End the tour. Confirm the 'Reset user tour on this page' link appears in the footer area (standard behaviour). Edit the admin/tool/usertours/templates/resettour.mustache template and add the following: {{#js}} alert("JS Was executed"); {{/js}} Refresh the Site Home page Confirm that the alert was shown Edit the columns2 template for your current theme and copy/paste the following to an additional place in the file: <div class="tool_usertours-resettourcontainer"></div> Refresh the Site Home page Confirm that the Reset link appears both in the footer (standard behaviour), and wherever you just added it
    • Affected Branches:
      MOODLE_33_STABLE, MOODLE_34_STABLE
    • Fixed Branches:
      MOODLE_34_STABLE
    • Pull from Repository:
    • Pull Master Branch:
      wip-MDL-60268-master

      Description

      Currently the Reset tour on page link is hard coded html injected into the page by javascript in usertours::addResetLink. It's injection is also limited to either the footer element or the logininfo div.

      We would like to suggest a small improvement by using a templated link. Other themes could then override the template if required. Also an improvement to finding a suitable place to append this link. By adding an initial check for a specific id (e.g. #tool_usertours-resettouronpage), a theme could place the link wherever it was wanted, rather than just in the footer area. 

        Attachments

          Activity

            People

            Assignee:
            jb23347 John Beedell
            Reporter:
            jb23347 John Beedell
            Peer reviewer:
            Tim Hunt
            Integrator:
            Andrew Nicols
            Tester:
            Andrew Nicols
            Participants:
            Component watchers:
            Andrew Nicols, Jun Pataleta, Michael Hawkins, Shamim Rezaie, Simey Lameze
            Votes:
            1 Vote for this issue
            Watchers:
            3 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:
              Fix Release Date:
              13/Nov/17