mirror of
https://github.com/moodle/moodle.git
synced 2025-08-05 08:56:36 +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);
|
$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)){
|
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);
|
$row[] = new tabobject('add', $CFG->wwwroot.'/mod/data/add.php?d='.$data->id, $addstring, '', true);
|
||||||
}
|
}
|
||||||
if (isteacher($course->id)) {
|
if (isteacher($course->id)) {
|
||||||
|
@ -65,13 +65,13 @@
|
||||||
*****************************/
|
*****************************/
|
||||||
if ($currenttab == 'templates' and isset($mode)) {
|
if ($currenttab == 'templates' and isset($mode)) {
|
||||||
$inactive[] = 'templates';
|
$inactive[] = 'templates';
|
||||||
$templatelist = array ('singletemplate', 'listtemplate', 'addtemplate', 'rsstemplate'); // Standard reports we want to show first
|
$templatelist = array ('singletemplate', 'listtemplate', 'addtemplate', 'rsstemplate', 'csstemplate');
|
||||||
|
|
||||||
$row = array();
|
$row = array();
|
||||||
$currenttab ='';
|
$currenttab ='';
|
||||||
foreach ($templatelist as $template) {
|
foreach ($templatelist as $template) {
|
||||||
$row[] = new tabobject($template, "templates.php?d=$data->id&mode=$template",
|
$row[] = new tabobject($template, "templates.php?d=$data->id&mode=$template",
|
||||||
get_string("$template", "data"));
|
get_string($template, 'data'));
|
||||||
if ($template == $mode) {
|
if ($template == $mode) {
|
||||||
$currenttab = $template;
|
$currenttab = $template;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue