mirror of
https://github.com/moodle/moodle.git
synced 2025-08-05 00:46:50 +02:00
Fixed a notice
This commit is contained in:
parent
f07fa64418
commit
01fe47f640
1 changed files with 3 additions and 3 deletions
|
@ -39,7 +39,7 @@
|
|||
$row[] = new tabobject('single', $CFG->wwwroot.'/mod/data/view.php?d='.$data->id.'&mode=single', get_string('detail','data'), '', true);
|
||||
}
|
||||
if (isteacher($course->id) or ($data->participants == DATA_STUDENTS_ONLY) or ($data->participants == DATA_TEACHERS_AND_STUDENTS)){
|
||||
$addstring = ($rid) ? get_string('editentry', 'data') : get_string('add', 'data');
|
||||
$addstring = empty($rid) ? get_string('add', 'data') : get_string('editentry', 'data');
|
||||
$row[] = new tabobject('add', $CFG->wwwroot.'/mod/data/add.php?d='.$data->id, $addstring, '', true);
|
||||
}
|
||||
if (isteacher($course->id)) {
|
||||
|
@ -65,13 +65,13 @@
|
|||
*****************************/
|
||||
if ($currenttab == 'templates' and isset($mode)) {
|
||||
$inactive[] = 'templates';
|
||||
$templatelist = array ('singletemplate', 'listtemplate', 'addtemplate', 'rsstemplate'); // Standard reports we want to show first
|
||||
$templatelist = array ('singletemplate', 'listtemplate', 'addtemplate', 'rsstemplate', 'csstemplate');
|
||||
|
||||
$row = array();
|
||||
$currenttab ='';
|
||||
foreach ($templatelist as $template) {
|
||||
$row[] = new tabobject($template, "templates.php?d=$data->id&mode=$template",
|
||||
get_string("$template", "data"));
|
||||
get_string($template, 'data'));
|
||||
if ($template == $mode) {
|
||||
$currenttab = $template;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue