Agenda: Fix attachment link UI see BT#16127

pull/2999/head
Julio Montoya 6 years ago
parent baa827304d
commit 266a0c4d2f
  1. 7
      main/calendar/agenda_js.php
  2. 13
      main/template/default/agenda/month.tpl

@ -279,11 +279,12 @@ if ($agenda->type === 'course') {
$form->addElement('checkbox', 'add_as_annonuncement', null, get_lang('AddAsAnnouncement'));
$form->addHtml('</div>');
$form->addElement('textarea', 'comment', get_lang('Comment'), ['id' => 'comment']);
$form->addHtml('<div id="attachment_block" style="display: none">');
$form->addLabel(get_lang('Attachment'), '<div id="attachment_text" style="display: none"></div>');
$form->addHtml('</div>');
}
$form->addHtml('<div id="attachment_block" style="display: none">');
$form->addLabel(get_lang('Attachment'), '<div id="attachment_text" style="display: none"></div>');
$form->addHtml('</div>');
$tpl->assign('form_add', $form->returnForm());
$tpl->assign('legend_list', api_get_configuration_value('agenda_legend'));

@ -47,7 +47,7 @@ $(document).ready(function() {
autoOpen : false,
modal : false,
width : 600,
height : 600,
height : 550,
zIndex : 20000 // added because of qtip2
});
@ -722,6 +722,8 @@ $(document).ready(function() {
$("#simple_title").html(calEvent.title);
$("#simple_content").html(calEvent.description);
$("#simple_comment").html(calEvent.comment);
$("#simple_attachment").html(calEvent.attachment);
$("#simple-dialog-form").dialog("open");
$("#simple-dialog-form").dialog({
buttons: {
@ -818,6 +820,15 @@ $(document).ready(function() {
<div id="simple_comment"></div>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">
<b>{{ "Attachment" |get_lang}}</b>
</label>
<div class="col-sm-9">
<div id="simple_attachment"></div>
</div>
</div>
</form>
</div>
</div>

Loading…
Cancel
Save