Uploaded image for project: 'Moodle app'
  1. Moodle app
  2. MOBILE-2900

Exclude enrolledusercount from enrol_get_users_courses web service call

XMLWordPrintable

    • Icon: Improvement Improvement
    • Resolution: Done
    • Icon: Critical Critical
    • 3.7.0
    • 3.6.1
    • Web Services
    • Hide

      Test on a device with remote debugging enabled.

      • Access a 3.7 site with a user that is enrolled in some courses.
      • Open the Chrome Development tools and filter the XHR requests.
      • Refresh the dashboard.
      • In the Development tools, find the WS call to "core_enrol_get_users_courses".
      • Check that the parameter "returnusercount" is passed with value "0".
      • Check that the response does not contain the field "enrolledusercount" in courses.
      • Access a 3.6 site with a user that is enrolled in some courses.
      • Check that the list of courses is displayed as usual.
      Show
      Test on a device with remote debugging enabled. Access a 3.7 site with a user that is enrolled in some courses. Open the Chrome Development tools and filter the XHR requests. Refresh the dashboard. In the Development tools, find the WS call to "core_enrol_get_users_courses". Check that the parameter "returnusercount" is passed with value "0". Check that the response does not contain the field "enrolledusercount" in courses. Access a 3.6 site with a user that is enrolled in some courses. Check that the list of courses is displayed as usual.
    • MOODLE_36_STABLE
    • MOODLE_37_STABLE
    • Moodle App 3.7.0

      As explained in MDL-64886, the call to enrol_get_users_courses to load the course overview currently counts the users on the course, which can hurt performance with large courses.  Since this is count is not used in the app, we should add {"returnusercount": false} to the parameters for this web service call in src/core/courses/providers/courses.ts::getUsersCourses

       

            albert.gasset Albert Gasset
            marxjohnson Mark Johnson
            Dani Palou Dani Palou
            Juan Leyva Juan Leyva
            Dani Palou Dani Palou
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved:

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