mirror of
https://github.com/moodle/moodle.git
synced 2025-08-05 17:06:53 +02:00
FIxes for bug 5197
This commit is contained in:
parent
354d3295d4
commit
3f9672d37c
2 changed files with 5 additions and 1 deletions
|
@ -1106,6 +1106,8 @@ function data_get_ratings($recordid, $sort="u.firstname ASC") {
|
||||||
//prints all comments + a text box for adding additional comment
|
//prints all comments + a text box for adding additional comment
|
||||||
function data_print_comments($data, $record, $page=0) {
|
function data_print_comments($data, $record, $page=0) {
|
||||||
|
|
||||||
|
global $CFG;
|
||||||
|
|
||||||
echo '<a name="comments"></a>';
|
echo '<a name="comments"></a>';
|
||||||
|
|
||||||
if ($comments = get_records('data_comments','recordid',$record->id)) {
|
if ($comments = get_records('data_comments','recordid',$record->id)) {
|
||||||
|
|
|
@ -229,7 +229,7 @@
|
||||||
'view.php?d='.$data->id);
|
'view.php?d='.$data->id);
|
||||||
|
|
||||||
$records[] = $deleterecord;
|
$records[] = $deleterecord;
|
||||||
data_print_template('singletemplate', $records, $data);
|
echo data_print_template('singletemplate', $records, $data, '', 0, true);
|
||||||
|
|
||||||
print_footer($course);
|
print_footer($course);
|
||||||
exit;
|
exit;
|
||||||
|
@ -417,6 +417,7 @@
|
||||||
|
|
||||||
if (empty($data->singletemplate)){
|
if (empty($data->singletemplate)){
|
||||||
notify(get_string('nosingletemplate','data'));
|
notify(get_string('nosingletemplate','data'));
|
||||||
|
data_generate_default_template($data, 'singletemplate', 0, false, false);
|
||||||
}
|
}
|
||||||
|
|
||||||
data_print_template('singletemplate', $records, $data, $search, $page);
|
data_print_template('singletemplate', $records, $data, $search, $page);
|
||||||
|
@ -430,6 +431,7 @@
|
||||||
|
|
||||||
if (empty($data->listtemplate)){
|
if (empty($data->listtemplate)){
|
||||||
notify(get_string('nolisttemplate','data'));
|
notify(get_string('nolisttemplate','data'));
|
||||||
|
data_generate_default_template($data, 'listtemplate', 0, false, false);
|
||||||
}
|
}
|
||||||
echo $data->listtemplateheader;
|
echo $data->listtemplateheader;
|
||||||
data_print_template('listtemplate', $records, $data, $search, $page);
|
data_print_template('listtemplate', $records, $data, $search, $page);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue