@@ -68,8 +68,8 @@ public function get_document_recordset($modifiedfrom = 0, \context $context = nu
68
68
WHERE mcd.timemodified >= ? AND mcc.component = 'mod_cms' AND mcc.area = 'cmsfield'
69
69
AND mcf.type IN ('textarea', 'text')
70
70
UNION
71
- SELECT mc.id, mc.course AS courseid, mc.typeid, null AS fieldname, null dataid ,
72
- null AS value, null AS valueformat,
71
+ SELECT mc.id, mc.course AS courseid, mc.typeid, null AS fieldname, null AS type ,
72
+ null AS dataid, null AS value, null AS valueformat,
73
73
mc.timecreated timecreated, mc.timemodified timemodified
74
74
FROM {cms} mc
75
75
LEFT JOIN {customfield_data} mcd ON mc.id = mcd.instanceid
@@ -123,7 +123,7 @@ public function get_document($record, $options = []) {
123
123
124
124
// Check if it's default value or not.
125
125
if (empty ($ record ->dataid )) {
126
- $ title = $ this ->defaultvalues [$ record ->typeid ]->fieldname ?? '' ;
126
+ $ title = $ this ->defaultvalues [$ record ->typeid ]->fieldname ?? '' ;
127
127
$ value = $ this ->defaultvalues [$ record ->typeid ]->value ?? '' ;
128
128
if (isset ($ this ->defaultvalues [$ record ->typeid ]->valueformat )) {
129
129
$ valueformat = $ this ->defaultvalues [$ record ->typeid ]->valueformat ;
0 commit comments