MDL-57273 core: Exporters support custom formatting parameters
This commit is contained in:
committed by
Damyon Wiese
parent
268beda8e9
commit
4bc68a416e
@@ -24,6 +24,7 @@
|
||||
namespace core_competency\external;
|
||||
defined('MOODLE_INTERNAL') || die();
|
||||
|
||||
use context_system;
|
||||
use core_user;
|
||||
use renderer_base;
|
||||
use stdClass;
|
||||
@@ -94,6 +95,17 @@ class user_competency_exporter extends \core\external\persistent_exporter {
|
||||
return (array) $result;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the format parameters for gradename.
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
protected function get_format_parameters_for_gradename() {
|
||||
return [
|
||||
'context' => context_system::instance(), // The system context is cached, so we can get it right away.
|
||||
];
|
||||
}
|
||||
|
||||
protected static function define_other_properties() {
|
||||
return array(
|
||||
'canrequestreview' => array(
|
||||
|
||||
Reference in New Issue
Block a user