diff --git a/main/announcements/announcements.inc.php b/main/announcements/announcements.inc.php index 92193a4e7a..d4fb07584c 100755 --- a/main/announcements/announcements.inc.php +++ b/main/announcements/announcements.inc.php @@ -142,9 +142,33 @@ class AnnouncementManager { $content = make_clickable($content); $content = text_filter($content); - echo "
".$title." | ||
| $content | ||
".$title." |
| $modify_icons |
|---|
| $content |
| " . get_lang('AnnouncementPublishedOn') . " : " .api_convert_and_format_date($result['end_date'], DATE_FORMAT_LONG). " |
| " . get_lang('LastUpdateDate') . " : " .api_convert_and_format_date($result['insert_date'], DATE_TIME_FORMAT_LONG). " |
| "; + $attachment_list = self::get_attachment($announcement_id); if (count($attachment_list)>0) { + echo " |
| "; $realname=$attachment_list['path']; $user_filename=$attachment_list['filename']; $full_file_name = 'download.php?file='.$realname; @@ -168,9 +193,8 @@ class AnnouncementManager { echo Display::return_icon('attachment.gif',get_lang('Attachment')); echo ' '.$user_filename.' '; echo ''.$attachment_list['comment'].''; - } - echo ' |
| ".get_lang("SentTo").": "; - $sent_to=sent_to(TOOL_CALENDAR_EVENT, $myrow["ref"]); - $sent_to_form=sent_to_form($sent_to); - echo $sent_to_form; - echo " | "; - + if (api_is_allowed_to_edit(false,true)) { if (!(api_is_course_coach() && !api_is_element_in_the_session(TOOL_AGENDA, $myrow['id']))) { @@ -2342,7 +2334,7 @@ function display_one_agenda_item($agenda_id) { $export_icon_low = '../img/export_low_fade.png'; $export_icon_high = '../img/export_high_fade.png'; - echo ''; + echo ' | '; if (!$repeat && api_is_allowed_to_edit(false,true)) { // edit $mylink = api_get_self()."?".api_get_cidreq()."&origin=".Security::remove_XSS($_GET['origin'])."&id=".$myrow['id']; @@ -2403,10 +2395,11 @@ function display_one_agenda_item($agenda_id) { echo $content; echo ' |
|---|---|---|
| '; + $attachment_list = get_attachment($agenda_id); if (!empty($attachment_list)) { + echo ' | ||
| ';
$realname=$attachment_list['path'];
$user_filename=$attachment_list['filename'];
$full_file_name = 'download.php?file='.$realname;
@@ -2415,24 +2408,30 @@ function display_one_agenda_item($agenda_id) {
if (api_is_allowed_to_edit()) {
echo ' '.Display::return_icon('delete.png',get_lang('Delete'),'',22).' '; } - echo ' '.$attachment_list['comment'].''; + echo ' '.$attachment_list['comment'].''; + echo ' | ||
| ".get_lang("SentTo").": "; + $sent_to=sent_to(TOOL_CALENDAR_EVENT, $myrow["ref"]); + $sent_to_form=sent_to_form($sent_to); + echo $sent_to_form; + echo " | ||
| '; echo get_lang('RepeatedEvent').' ',get_lang('RepeatedEventViewOriginalEvent'),''; echo ' | '; echo '||
| ";
echo "".get_lang("AddedResources")." "; @@ -2451,8 +2450,6 @@ function display_one_agenda_item($agenda_id) { } - - /** * Show the form for adding a new agenda item. This is the same function that is used whenever we are editing an * agenda item. When the id parameter is empty (default behaviour), then we show an empty form, else we are editing and | ||