11 Commits

Author SHA1 Message Date
Damyon Wiese
ba224fb42c MDL-50783 Ajax: Configure how to call a webservice through db/service.php
Now the db/service.php array can contain these extra keys to provide information
on how a webservice may be called:

    'ajax' => true (Default is false)

Replaces the xx_is_allowed_from_ajax callback.

    'loginrequired' => false (Default is true)

Means that this webservice can be called through lib/ajax/service-nosession.php
which sets NO_MOODLE_COOKIES to true (faster). This is only safe for webservices returning
static public data (e.g. get_string).
2015-09-14 15:10:21 +08:00
Damyon Wiese
72f8324ec5 MDL-49163 Webservices, AJAX: Add support for a new ajax webservice handler.
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.
2015-03-12 15:07:08 +08:00
Damyon Wiese
bef63c520c MDL-49240 webservices: core_get_string and friends bad lang handling
The core_get_string webservice and friends have never passed lang values
properly, (so never worked) and when I fixed that I found they were passing
lang parameter into the lazyload parameter.
2015-02-24 15:32:17 +08:00
Tim Hunt
5bcfd504df MDL-45618 Fix @since PHPdoc tags. 2014-05-19 17:03:04 +01:00
Petr Škoda
5d071be68e MDL-41022 cleanup core_external_testcase 2013-08-24 16:18:18 +02:00
Petr Škoda
8252b7c291 MDL-40901 standardise core test case class and file names
This finally allows us to type only the class name when executing individual core test cases.
2013-08-04 22:10:31 +02:00
Eloy Lafuente (stronk7)
493d8f781c Merge branch 'MDL-37354-master' of git://github.com/mouneyrac/moodle
Conflicts:
	message/tests/externallib_test.php
2013-01-15 21:50:31 +01:00
Jerome Mouneyrac
fb695f6e3d MDL-37354 clean return value for each externallib PHPUnit tests 2013-01-09 13:47:01 +08:00
Jerome Mouneyrac
c5f7628d39 MDL-37381 core_external::get_component_strings returns wrong format value 2013-01-08 16:23:24 +08:00
Sam Hemelryk
fd6ab92b1d Merge branch 'MDL-35997-wip1' of git://github.com/mouneyrac/moodle
Conflicts:
	version.php
2012-11-28 10:57:09 +13:00
Jerome Mouneyrac
11e766020b MDL-35997 Create web service functions to return lang strings 2012-10-31 14:21:56 +08:00