move events tools to aside widget

This commit is contained in:
Mario Vavti
2015-11-27 22:45:28 +01:00
parent b92cc852d1
commit bcfa72ed31
5 changed files with 34 additions and 25 deletions

View File

@@ -666,7 +666,7 @@ function widget_eventsmenu($arr) {
if (! local_channel())
return;
return replace_macros(get_markup_template('events_side.tpl'), array(
return replace_macros(get_markup_template('events_menu_side.tpl'), array(
'$title' => t('Events Menu'),
'$day' => t('Day View'),
'$week' => t('Week View'),
@@ -677,6 +677,18 @@ function widget_eventsmenu($arr) {
));
}
function widget_eventstools($arr) {
if (! local_channel())
return;
return replace_macros(get_markup_template('events_tools_side.tpl'), array(
'$title' => t('Events Tools'),
'$export' => t('Export Calendar'),
'$import' => t('Import Calendar'),
'$submit' => t('Submit')
));
}
function widget_design_tools($arr) {
$a = get_app();
@@ -1147,6 +1159,8 @@ function widget_forums($arr) {
function widget_tasklist($arr) {
if (! local_channel())
return;
require_once('include/event.php');
$o .= '<script>var tasksShowAll = 0; $(document).ready(function() { tasksFetch(); $("#tasklist-new-form").submit(function(event) { event.preventDefault(); $.post( "tasks/new", $("#tasklist-new-form").serialize(), function(data) { tasksFetch(); $("#tasklist-new-summary").val(""); } ); return false; } )});</script>';