From a71a3aefe0c0508b45c32932789bb7646b7d6049 Mon Sep 17 00:00:00 2001 From: skodak Date: Tue, 19 Feb 2008 10:46:10 +0000 Subject: [PATCH] MDL-11843 deleting of activities directly from calendar is dangerous/confusing; merged from MOODLE_19_STABLE --- calendar/lib.php | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/calendar/lib.php b/calendar/lib.php index dbeb4a6a951..703d88db9ec 100644 --- a/calendar/lib.php +++ b/calendar/lib.php @@ -557,14 +557,16 @@ function calendar_print_event($event) { $deletelink = CALENDAR_URL.'event.php?action=delete&id='.$event->id.$calendarcourseid; } else { $editlink = $CFG->wwwroot.'/course/mod.php?update='.$event->cmid.'&return=true&sesskey='.$USER->sesskey; - $deletelink = $CFG->wwwroot.'/course/mod.php?delete='.$event->cmid.'&sesskey='.$USER->sesskey;; + $deletelink = ''; // deleting activities directly from calendar is dangerous/confusing - see MDL-11843 } echo ' '.get_string('tt_editevent', 'calendar').''; - echo ' '.get_string('tt_deleteevent', 'calendar').''; + if ($deletelink) { + echo ' '.get_string('tt_deleteevent', 'calendar').''; + } echo ''; } echo '';