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

Implement share progress page for content shared to MoodleNet

    XMLWordPrintable

Details

    • MOODLE_401_STABLE, MOODLE_402_STABLE
    • MOODLE_403_STABLE
    • MDL-75502-master
    • Hide

      Partially covered by Behat tests

      Initial setup

      1. Set up and run the MoodleNet mock server (https://github.com/moodlehq/moodlenet_mock) using 'moodlenet.test' as the domain.
      2. Log in as Admin.
      3. Navigate to Site admin > Security > HTTP security and clear the values for "cURL blocked hosts list" and "cURL allowed ports list" so they do not prevent us from reaching the MoodleNet mock server.
      4. Navigate to Site admin > Development > Experimental
      5. Enable the "Enable sharing to MoodleNet" setting.
      6. Navigate to Site Admin > Server > OAuth 2 services.
      7. Click on the "MoodleNet" button.
      8. Change the Service base URL to: https://moodlenet.test
      9. Change the Name to: MoodleNet Local
      10. Save changes.
      11. Navigate to Site Admin > General > MoodleNet outbound settings.
      12. Select "MoodleNet Local" in the OAuth 2 service dropdown.
      13. Press "Save changes".

      Test scenario (share course)

      1. Create a new Course.
      2. Navigate to the Course.
      3. Click the "More" menu and choose "Share to MoodleNet".
      4. Press "Share".
      5. If you get a popup from the oAuth2 service, press "Allow".
      6. After successfully sharing, close the modal window and click the "More" menu again.
      7. CONFIRM that there is a menu item called "Shared to MoodleNet".
      8. Choose "MoodleNet share progress" from the menu.
      9. CONFIRM you see the course share in the table with the status "Sent".

      Test scenario (share activity)

      1. Navigate to your course.
      2. Create a new activity.
      3. Navigate to the new activity.
      4. Click the "More" menu and choose "Share to MoodleNet".
      5. Press "Share".
      6. After successfully sharing, close the modal window, navigate back the Course page and click the "More" menu again.
      7. CONFIRM that there is a menu item called "Shared to MoodleNet".
      8. Choose "MoodleNet share progress" from the menu.
      9. CONFIRM you see the activity share in the table with the status "Sent".

      Manual status manipulation

      It is currently difficult to simulate an 'error', 'in progress' and 'deleted' status on the MoodleNet share progress page. This will be easier with future improvements like MDL-78271

      This test will require access to the moodlenet_share_progress table in the Moodle database.

      1. Find the entries in the moodlenet_share_progress table for a shared course that you performed in the previous tests.
      2. The status field should contain the value "1". Change this value to "2".
      3. Refresh the MoodleNet share progress page.
      4. CONFIRM that the status badge now reads "In progress".
      5. Change the status field again to "3".
      6. Refresh the MoodleNet share progress page.
      7. CONFIRM that the status badge now reads "Error".
      8. Finally, delete the course from Moodle.
      9. Refresh the MoodleNet share progress page.
      10. CONFIRM that the course name has been changed to "Deleted course".
      11. Do the same manipulation to an activity in the moodlenet_share_progress table and confirm that you eventually get the changed name of "Deleted activity"
      Show
      Partially covered by Behat tests Initial setup Set up and run the MoodleNet mock server ( https://github.com/moodlehq/moodlenet_mock ) using 'moodlenet.test' as the domain. Log in as Admin. Navigate to Site admin > Security > HTTP security and clear the values for "cURL blocked hosts list" and "cURL allowed ports list" so they do not prevent us from reaching the MoodleNet mock server. Navigate to Site admin > Development > Experimental Enable the "Enable sharing to MoodleNet" setting. Navigate to Site Admin > Server > OAuth 2 services. Click on the "MoodleNet" button. Change the Service base URL to: https://moodlenet.test Change the Name to: MoodleNet Local Save changes. Navigate to Site Admin > General > MoodleNet outbound settings. Select "MoodleNet Local" in the OAuth 2 service dropdown. Press "Save changes". Test scenario (share course) Create a new Course. Navigate to the Course. Click the "More" menu and choose "Share to MoodleNet". Press "Share". If you get a popup from the oAuth2 service, press "Allow". After successfully sharing, close the modal window and click the "More" menu again. CONFIRM that there is a menu item called "Shared to MoodleNet". Choose "MoodleNet share progress" from the menu. CONFIRM you see the course share in the table with the status "Sent". Test scenario (share activity) Navigate to your course. Create a new activity. Navigate to the new activity. Click the "More" menu and choose "Share to MoodleNet". Press "Share". After successfully sharing, close the modal window, navigate back the Course page and click the "More" menu again. CONFIRM that there is a menu item called "Shared to MoodleNet". Choose "MoodleNet share progress" from the menu. CONFIRM you see the activity share in the table with the status "Sent". Manual status manipulation It is currently difficult to simulate an 'error', 'in progress' and 'deleted' status on the MoodleNet share progress page. This will be easier with future improvements like MDL-78271 .  This test will require access to the moodlenet_share_progress table in the Moodle database. Find the entries in the moodlenet_share_progress table for a shared course that you performed in the previous tests. The status field should contain the value "1". Change this value to "2". Refresh the MoodleNet share progress page. CONFIRM that the status badge now reads "In progress". Change the status field again to "3". Refresh the MoodleNet share progress page. CONFIRM that the status badge now reads "Error". Finally, delete the course from Moodle. Refresh the MoodleNet share progress page. CONFIRM that the course name has been changed to "Deleted course". Do the same manipulation to an activity in the moodlenet_share_progress table and confirm that you eventually get the changed name of "Deleted activity"
    • 6
    • Team Hedgehog 2023 Sprint 2.2, Team Hedgehog 2023 Sprint 2.3, Team Hedgehog 2023 Review 2, Team Hedgehog 2023 Sprint 3.1, Team Hedgehog 2023 Sprint 3.2

    Description

      This issue resolves the following user story: As a teacher, I need the ability to view the current send status of content I have recently shared to MoodleNet from the current Moodle site, so that I know when I can visit the respective MoodleNet draft to complete and publish the resource.

      Requirements

      1. Teachers can access the share progress from their user dropdown menu. To simplify the logic required (and improve performance), teachers can access the share progress from the More menu within a course where they have the capability to share activities or courses.
      2. We need to create a new page to render this information.
      3. A table on the page including name (activity or course name), type (activity type or "Course"), send date, send status (Sent, In progress, Error).
      4. The table should be automatically sorted by send status (Error first, then In progress, then Sent), then by send date/time (newest first). For example, the most recent one to fail/error would be the first item at the top of the list.
      5. When a share has completed successfully, the resource name should become a hyperlink to the MoodleNet resource's draft URL.
      6. Include pagination, won't always be required, but will be useful in cases where someone shares a lot before checking back on the list. Possibly 25 items per page would be ideal.
      7. Ensure there is an appropriate zero state (an indication on the page when there are no shares to view).
      8. Before allowing this new page to render successfully and attempt to fetch any data, we should check that the visiting user is logged in, not a guest, and has at least one of the relevant activity/course sharing capabilities (in any context) before allowing the page to render (with appropriate caching). This is to avoid having a page which can be directly accessed by a user when it's not possible to reach it via the UI.
      9. Behat/unit tests implemented as applicable.

      The information required to fulfill requirements 3-4 will be available once MDL-77296 is implemented.

      Out of scope

      • Clean up/clearing of the share progress data. This will be implemented in MDL-78422.
      • User filtering/sorting of table data. With requirement 4 in place, priority information will be surfaced, and with the above cleanup implemented, the data listed will be temporary.
      • Accessing the share progress from the share modal (this will need to be implemented as part of MDL-78271).
      • Ability to expand a course shares to view activity details - this is a high level overview of recent upload progress, so granular details are not required.
      • Linking to the relevant activity/course within the LMS.
      • Granular progress updates (eg upload percentage that are more detailed than the listed requirements).
      • Any content relating to MN => Moodle transfers.

      Prototype

      Figma prototype

      Attachments

        Issue Links

          Activity

            People

              david.woloszyn@moodle.com David Woloszyn
              michaelh Michael Hawkins
              Meirza Meirza
              Huong Nguyen Huong Nguyen
              Ron Carl Alfon Yu Ron Carl Alfon Yu
              Votes:
              0 Vote for this issue
              Watchers:
              7 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - 0 minutes
                  0m
                  Remaining:
                  Remaining Estimate - 0 minutes
                  0m
                  Logged:
                  Time Spent - 1 week, 3 days, 1 hour, 7 minutes
                  1w 3d 1h 7m

                  Clockify

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