MDL-54546 tool_lp: Use correct property types for user/course exporters

This commit is contained in:
Jun Pataleta 2016-05-12 13:50:46 +08:00
parent e4b5a062d8
commit e5336562db
2 changed files with 10 additions and 10 deletions

View File

@ -58,7 +58,7 @@ class course_summary_exporter extends \core_competency\external\exporter {
'type' => PARAM_TEXT,
),
'idnumber' => array(
'type' => PARAM_TEXT,
'type' => PARAM_RAW,
)
);
}

View File

@ -69,30 +69,30 @@ class user_summary_exporter extends exporter {
public static function define_properties() {
return array(
'id' => array(
'type' => PARAM_INT,
'type' => \core_user::get_property_type('id'),
),
'email' => array(
'type' => PARAM_TEXT,
'type' => \core_user::get_property_type('email'),
'default' => ''
),
'idnumber' => array(
'type' => PARAM_NOTAGS,
'type' => \core_user::get_property_type('idnumber'),
'default' => ''
),
'phone1' => array(
'type' => PARAM_NOTAGS,
'type' => \core_user::get_property_type('phone1'),
'default' => ''
),
'phone2' => array(
'type' => PARAM_NOTAGS,
'type' => \core_user::get_property_type('phone2'),
'default' => ''
),
'department' => array(
'type' => PARAM_TEXT,
'type' => \core_user::get_property_type('department'),
'default' => ''
),
'institution' => array(
'type' => PARAM_TEXT,
'type' => \core_user::get_property_type('institution'),
'default' => ''
)
);
@ -101,10 +101,10 @@ class user_summary_exporter extends exporter {
public static function define_other_properties() {
return array(
'fullname' => array(
'type' => PARAM_TEXT
'type' => PARAM_RAW
),
'identity' => array(
'type' => PARAM_TEXT
'type' => PARAM_RAW
),
'profileurl' => array(
'type' => PARAM_URL