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

Report Builder Preview and Edit buttons do not indicate to the user that something is happening

    XMLWordPrintable

Details

    • MOODLE_401_STABLE
    • MOODLE_401_STABLE
    • Hide

      To simulate a "slow" report, we'll add an artificial delay so that the effects of this change are more obvious

      1. Edit the file reportbuilder/classes/table/base_report_table.php, in the query_db as follows (around line 160):

            public function query_db($pagesize, $useinitialsbar = true) {
                sleep(2); // <-- ADD THIS LINE.
                global $DB;
        

      2. Navigate to Reports from user menu
      3. Create new report from Users report source (with default setup)
      4. Press Preview
      5. Confirm you see a loading spinner after pressing the button
      6. Confirm report preview loads
      7. Press Edit
      8. Confirm you see a loading spinner after pressing the button
      9. Confirm report editor loads
      Show
      To simulate a "slow" report, we'll add an artificial delay so that the effects of this change are more obvious Edit the file reportbuilder/classes/table/base_report_table.php , in the query_db as follows (around line 160): public function query_db($pagesize, $useinitialsbar = true) { sleep(2); // <-- ADD THIS LINE. global $DB; Navigate to Reports from user menu Create new report from Users report source (with default setup) Press Preview Confirm you see a loading spinner after pressing the button Confirm report preview loads Press Edit Confirm you see a loading spinner after pressing the button Confirm report editor loads

    Description

      When using the Report Builder, there is a no indication to the user that the Report Preview (when clicking the Preview button from the Report Editor) or Report Editor (when clicking the Edit button from the Report Preview) is loading (via AJAX), leading to user confusion. This becomes especially important when the Report in question takes more than a few milliseconds to change to the appropriate view.

      Minimally, something should happen to indicate to the user that 1) the button was successfully clicked and 2) something is happening. CSS supports a couple of possible values: `progress` and `wait`.

      Attachments

        1. 1_MDL-75723_master.png
          1_MDL-75723_master.png
          3 kB
        2. 2_MDL-75723_master.png
          2_MDL-75723_master.png
          36 kB
        3. 3_MDL-75723_master.png
          3_MDL-75723_master.png
          2 kB
        4. 4_MDL-75723_master.png
          4_MDL-75723_master.png
          28 kB

        Issue Links

          Activity

            People

              pholden Paul Holden
              matt.rice Matt Rice
              Carlos Castillo Carlos Castillo
              Victor Déniz Falcón Victor Déniz Falcón
              John Edward Pedregosa John Edward Pedregosa
              Carlos Castillo, David Matamoros, Mikel Martín Corrales, Paul Holden
              Votes:
              1 Vote for this issue
              Watchers:
              7 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:
                28/Nov/22

                Time Tracking

                  Estimated:
                  Original Estimate - 0 minutes
                  0m
                  Remaining:
                  Remaining Estimate - 0 minutes
                  0m
                  Logged:
                  Time Spent - 2 hours, 30 minutes
                  2h 30m