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

Move the report builder "toggle" template to core

XMLWordPrintable

    • MOODLE_400_STABLE
    • MOODLE_400_STABLE
    • Hide

      Setup

      1. Run grunt componentlibrary
      2. Login as admin
      3. Navigate to Reports > Report builder > Custom reports in site administration
      4. Create a new report from the Users report source
      5. Press the Audience tab
      6. Add All users audience
      7. Press Schedules tab
      8. Press New schedule with following configuration:
        • Name: Schedule 01
        • Audience: All users: All site users
        • Subject: Schedule 01
        • Body: Something very interesting

      Test no regressions were added

      1. Confirm Schedule 01 toggle is enabled
      2. Click on Schedule 01 toggle input
      3. Confirm Schedule 01 toggle is disabled
      4. Reload the browser page
      5. Confirm Schedule 01 toggle is still disabled
      6. Click on Schedule 01 toggle input
      7. Confirm Schedule 01 toggle is now enabled
      8. Reload the browser page
      9. Confirm Schedule 01 toggle is still enabled

      Test labels are shown correctly

      1. Open browser inspector
      2. Confirm that <span class="sr-only"> element that is inside toggle contains "Disable schedule"
      3. Click on Schedule 01 toggle input
      4. Confirm that <span class="sr-only"> element that is inside toggle contains "Enable schedule"

      Test component library

      1. Navigate to Development > UI Component library in site administration
      2. Navigate to Moodle > Moodle components > Toggle input in component library
      3. Confirm documentation is correct
      4. Confirm examples work correctly
      Show
      Setup Run grunt componentlibrary Login as admin Navigate to Reports > Report builder > Custom reports in site administration Create a new report from the Users report source Press the Audience tab Add All users audience Press Schedules tab Press New schedule with following configuration: Name: Schedule 01 Audience: All users: All site users Subject: Schedule 01 Body: Something very interesting Test no regressions were added Confirm Schedule 01 toggle is enabled Click on Schedule 01 toggle input Confirm Schedule 01 toggle is disabled Reload the browser page Confirm Schedule 01 toggle is still disabled Click on Schedule 01 toggle input Confirm Schedule 01 toggle is now enabled Reload the browser page Confirm Schedule 01 toggle is still enabled Test labels are shown correctly Open browser inspector Confirm that <span class="sr-only"> element that is inside toggle contains "Disable schedule" Click on Schedule 01 toggle input Confirm that <span class="sr-only"> element that is inside toggle contains "Enable schedule" Test component library Navigate to Development > UI Component library in site administration Navigate to Moodle > Moodle components > Toggle input  in component library Confirm documentation is correct Confirm examples work correctly

      As requested by sarjona  in her review of MDL-72598: https://tracker.moodle.org/browse/MDL-72598?focusedCommentId=893655&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-893655

      I have only one comment: I think the reportbuilder/templates/local/toggle.mustache you have created should be moved to the main library and be added to the component UI library. I'm not going to block this issue for that (because we're trying to introduce the Component library little by little, as we did with other features in the past, such as unit tests), but I think it should be done before the 4.0 release. Please, could you create a new issue and prepare a patch for it

            mikelmartíncorrales Mikel Martín Corrales
            pholden Paul Holden
            Paul Holden Paul Holden
            Jun Pataleta Jun Pataleta
            Angelia Dela Cruz Angelia Dela Cruz
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved:

                Estimated:
                Original Estimate - 0 minutes
                0m
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 1 day, 15 minutes
                1d 15m

                  Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.