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

Ajax webservice uses wrong renderer by default

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Minor Minor
    • 3.1.4
    • 3.2
    • Web Services
    • MOODLE_32_STABLE
    • MOODLE_31_STABLE
    • MDL-56958-master
    • Hide

      In the current theme - override single button so it looks different. (Boost does this already)

      View the manage competency frameworks page. Duplicate a framework. Verify the "Add" button does not change in appearance.

      Show
      In the current theme - override single button so it looks different. (Boost does this already) View the manage competency frameworks page. Duplicate a framework. Verify the "Add" button does not change in appearance.

      When calling the ajax webservice script - /lib/ajax/service.php because AJAX_SCRIPT is defined, any webservice that is called will get the "_ajax" renderer by default. In any theme (boost) - unless we define an ajax renderer (can't extend the base one - needs to duplicate the whole thing) we will get the core ajax renderer which only falls back on the core_renderer (not the one from the theme).

      If we are returning some HTML as part of a web-service response, we are not expecting the AJAX renderer - it does weird things like removing all headers etc. The AJAX renderer also handles custom error formatting - but we do that anyway in external_api::call_external_function.

      So - anything that goes through /lib/ajax/service.php should prefer the GENERAL renderer instead.

            damyon Damyon Wiese
            damyon Damyon Wiese
            Mark Nelson Mark Nelson
            Andrew Lyons Andrew Lyons
            Jun Pataleta Jun Pataleta
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved:

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