1. 14 Apr, 2016 2 commits
    • Damyon Wiese's avatar
      MDL-53772 libraries: More context fixes · e02e7f5a
      Damyon Wiese authored and David Monllaó's avatar David Monllaó committed
      1. Improve upgrade note
      2. Don't abuse $PAGE to get the current course/cm
      3. Use validate_context, never $PAGE->set_context()
      4. Reset current coursemodule in validate_context().
      5. Respect moodlepageclass when calling an external function.
      e02e7f5a
    • Damyon Wiese's avatar
      MDL-53772 externallib: Fix busted webservices context handling · 56fa860e
      Damyon Wiese authored
      Fix:
      $PAGE->context must be reset when calling validate_context
      
      Improve:
      Provide wrapper for calling an external function
      
      The wrapper correctly checks the function parameters and return type against
      the description of the external function, and stores the PAGE and COURSE global
      state variables, restoring them before the function returns.
      
      Fix: buggy unit tests.
      
      These tests are expecting debugging from a bug that was fixed, and calling web
      service functions with no user or session.
      56fa860e
  2. 12 Apr, 2016 2 commits
  3. 03 Dec, 2015 1 commit
  4. 15 Oct, 2015 1 commit
  5. 12 Oct, 2015 1 commit
  6. 14 Sep, 2015 2 commits
  7. 10 Sep, 2015 1 commit
  8. 09 Sep, 2015 1 commit
  9. 08 Sep, 2015 1 commit
    • Damyon Wiese's avatar
      MDL-50782 Ajax: No require_login for all ajax webservice calls · 5d8c1987
      Damyon Wiese authored
      Some webservice functions need to be available without a login, e.g.
      fetching strings and templates.
      
      External functions must call validate_context if they require a valid login etc.
      
      Added a new parameter to services.php: "loginrequired". Default is true.
      5d8c1987
  10. 27 Aug, 2015 1 commit
    • Damyon Wiese's avatar
      MDL-51213 externallib: external_format_text/external_format_string · 9764aab9
      Damyon Wiese authored
      API functions do not know if they are being called from a web page, or a
      web-service. They need a single function to call to correctly apply
      filters, strip tags etc that knows the correct way to do this based on
      the way it was called (e.g. webservices allow parameters for skipping
      filters etc).
      
      So here we are fixing the default for the filter argument used in
      external_format_text and adding a matching external_format_string.
      9764aab9
  11. 06 May, 2015 1 commit
  12. 12 Mar, 2015 1 commit
    • Damyon Wiese's avatar
      MDL-49163 Webservices, AJAX: Add support for a new ajax webservice handler. · 72f8324e
      Damyon Wiese authored
      This is a new script that can call any function in the built-in AJAX webservice. This is
      a new system service that is added at install time (like the mobile webservice). It has no
      protocols added to it, but it accessible by a new ajax script /lib/ajax/service.php.
      
      Requests and responses to the script are required to be in json format, and multiple functions can
      be called in a single request.
      72f8324e
  13. 09 Feb, 2015 1 commit
  14. 12 Sep, 2014 2 commits
  15. 20 May, 2014 1 commit
  16. 15 Mar, 2014 1 commit
  17. 07 Nov, 2013 1 commit
  18. 17 Jul, 2013 1 commit
  19. 09 Jul, 2013 1 commit
  20. 17 Jun, 2013 1 commit
  21. 14 Jun, 2013 1 commit
  22. 07 May, 2013 1 commit
  23. 07 Jan, 2013 1 commit
  24. 13 Dec, 2012 1 commit
  25. 24 Aug, 2012 1 commit
  26. 27 Jul, 2012 1 commit
  27. 06 Jun, 2012 1 commit
  28. 31 May, 2012 1 commit
  29. 15 May, 2012 2 commits
  30. 30 Apr, 2012 1 commit
  31. 11 Apr, 2012 1 commit
  32. 27 Mar, 2012 1 commit
  33. 07 Oct, 2011 1 commit
  34. 26 Jul, 2011 1 commit
  35. 30 Nov, 2010 1 commit