aboutsummaryrefslogtreecommitdiff
path: root/views/default/event_calendar
diff options
context:
space:
mode:
Diffstat (limited to 'views/default/event_calendar')
-rw-r--r--views/default/event_calendar/css.php7
-rw-r--r--views/default/event_calendar/datetime_edit.php12
-rw-r--r--views/default/event_calendar/full_calendar_view.php2
-rw-r--r--views/default/event_calendar/personal_manage_section.php20
-rw-r--r--views/default/event_calendar/reminder_section.php28
-rw-r--r--views/default/event_calendar/schedule_section.php22
-rw-r--r--views/default/event_calendar/share_section.php26
7 files changed, 109 insertions, 8 deletions
diff --git a/views/default/event_calendar/css.php b/views/default/event_calendar/css.php
index 4d68f500f..9461a7fe9 100644
--- a/views/default/event_calendar/css.php
+++ b/views/default/event_calendar/css.php
@@ -269,4 +269,9 @@ li.event-calendar-filter-menu-show-only {
.event-calendar-description {
display: none;
-} \ No newline at end of file
+}
+
+.event-calendar-edit-bottom {
+ clear: both;
+ margin-bottom: 5px;
+}
diff --git a/views/default/event_calendar/datetime_edit.php b/views/default/event_calendar/datetime_edit.php
index aa3a8f2de..ceceeb20e 100644
--- a/views/default/event_calendar/datetime_edit.php
+++ b/views/default/event_calendar/datetime_edit.php
@@ -9,16 +9,16 @@ if ($event_calendar_times != 'no') {
$body .= '<p><label>'.elgg_echo('event_calendar:from_label').'</label>';
}
$body .= elgg_view("event_calendar/input/date_local",array(
- 'timestamp'=>TRUE,
+ //'timestamp'=>TRUE,
'autocomplete'=>'off',
'class'=>'event-calendar-compressed-date',
'name' => 'start_date',
'value'=>$vars['start_date']));
$body .= elgg_view("input/timepicker",array('name' => 'start_time','value'=>$vars['start_time']));
if ($event_calendar_hide_end != 'yes') {
- $body .= '</p><p><label>'.elgg_echo('event_calendar:to_label').'</label>';
+ $body .= '</p><p id="event-calendar-to-time-wrapper"><label>'.elgg_echo('event_calendar:to_label').'</label>';
$body .= elgg_view("event_calendar/input/date_local",array(
- 'timestamp'=>TRUE,
+ //'timestamp'=>TRUE,
'autocomplete'=>'off',
'class'=>'event-calendar-compressed-date',
'name' => 'end_date',
@@ -26,7 +26,7 @@ if ($event_calendar_times != 'no') {
));
$body .= elgg_view("input/timepicker",array('name' => 'end_time','value'=>$vars['end_time']));
}
- $body .= '</p>';
+ $body .= '</p></span>';
} else {
$body .= '<p><label>'.elgg_echo("event_calendar:start_date_label").'<br />';
@@ -35,10 +35,10 @@ if ($event_calendar_times != 'no') {
$body .= '<p class="description">'.$prefix['start_date'].elgg_echo('event_calendar:start_date_description').'</p>';
if ($event_calendar_hide_end != 'yes') {
- $body .= '<p><label>'.elgg_echo("event_calendar:end_date_label").'<br />';
+ $body .= '<p id="event-calendar-to-time-wrapper"><label>'.elgg_echo("event_calendar:end_date_label").'<br />';
$body .= elgg_view("event_calendar/input/date_local",array('timestamp'=>TRUE,'autocomplete'=>'off','name' => 'end_date','value'=>$vars['end_date']));
$body .= '</label></p>';
- $body .= '<p class="description">'.$prefix['end_date'].elgg_echo('event_calendar:end_date_description').'</p>';
+ //$body .= '<p class="description">'.$prefix['end_date'].elgg_echo('event_calendar:end_date_description').'</p>';
}
}
diff --git a/views/default/event_calendar/full_calendar_view.php b/views/default/event_calendar/full_calendar_view.php
index 6c21c42c8..5fffff624 100644
--- a/views/default/event_calendar/full_calendar_view.php
+++ b/views/default/event_calendar/full_calendar_view.php
@@ -14,7 +14,7 @@ handleEventClick = function(event) {
handleEventDrop = function(event,dayDelta,minuteDelta,allDay,revertFunc) {
- if (!confirm("Are you sure about this change?")) {
+ if (!confirm("<?php echo elgg_echo('event_calendar:are_you_sure'); ?>")) {
revertFunc();
} else {
elgg.action('event_calendar/modify_full_calendar',
diff --git a/views/default/event_calendar/personal_manage_section.php b/views/default/event_calendar/personal_manage_section.php
new file mode 100644
index 000000000..9e03db0ab
--- /dev/null
+++ b/views/default/event_calendar/personal_manage_section.php
@@ -0,0 +1,20 @@
+<?php
+$fd = $vars['form_data'];
+$event_calendar_personal_manage = elgg_get_plugin_setting('personal_manage', 'event_calendar');
+$body = '';
+
+if ($event_calendar_personal_manage == 'by_event') {
+ $personal_manage_options = array(
+ elgg_echo('event_calendar:personal_manage:by_event:open') => 'open',
+ elgg_echo('event_calendar:personal_manage:by_event:closed') => 'closed',
+ elgg_echo('event_calendar:personal_manage:by_event:private') => 'private',
+ );
+ $body .= '<div class="event-calendar-edit-form-block event-calendar-edit-form-membership-block">';
+ $body .= '<h2>'.elgg_echo('event_calendar:personal_manage:label').'</h2>';
+ $body .= elgg_view("input/radio",array('name' => 'personal_manage','value'=>$fd['personal_manage'],'options'=>$personal_manage_options));
+ //$body .= '<p class="event-calendar-description">'.$prefix['personal_manage'].elgg_echo('event_calendar:personal_manage:description').'</p>';
+ $body .= '<br clear="both" />';
+ $body .= '</div>';
+}
+
+echo $body;
diff --git a/views/default/event_calendar/reminder_section.php b/views/default/event_calendar/reminder_section.php
new file mode 100644
index 000000000..fffa6d065
--- /dev/null
+++ b/views/default/event_calendar/reminder_section.php
@@ -0,0 +1,28 @@
+<?php
+$fd = $vars['form_data'];
+$event_calendar_reminders = elgg_get_plugin_setting('reminders', 'event_calendar');
+$body = '';
+if ($event_calendar_reminders == 'yes') {
+ $body .= '<div class="event-calendar-edit-reminder-wrapper">';
+ if ($fd['send_reminder']) {
+ $body .= elgg_view('input/checkbox',array('name'=>'send_reminder','checked' => 'checked','value'=>1));
+ } else {
+ $body .= elgg_view('input/checkbox',array('name'=>'send_reminder','value'=>1));
+ }
+ $body .= elgg_echo('elgg_calendar:send_reminder_label'). ' ';
+ $numbers = array();
+ for ($i=1;$i<60;$i++) {
+ $numbers[$i] = $i;
+ }
+ $intervals = array(
+ 1 => elgg_echo('event_calendar:interval:minute'),
+ 60 => elgg_echo('event_calendar:interval:hour'),
+ 60*24 => elgg_echo('event_calendar:interval:day'),
+ );
+
+ $body .= elgg_view('input/dropdown',array('name'=>'reminder_number','options_values'=>$numbers,'value'=>$fd['reminder_number']));
+ $body .= elgg_view('input/dropdown',array('name'=>'reminder_interval','options_values'=>$intervals,'value'=>$fd['reminder_interval']));
+ $body .= elgg_echo('elgg_calendar:send_reminder_before');
+ $body .= '</div>';
+}
+echo $body;
diff --git a/views/default/event_calendar/schedule_section.php b/views/default/event_calendar/schedule_section.php
new file mode 100644
index 000000000..3a74dc789
--- /dev/null
+++ b/views/default/event_calendar/schedule_section.php
@@ -0,0 +1,22 @@
+<?php
+$event = $vars['event'];
+$fd = $vars['form_data'];
+$event_calendar_repeated_events = elgg_get_plugin_setting('repeated_events', 'event_calendar');
+
+$body = '<div class="event-calendar-edit-date-wrapper">';
+$body .= elgg_view('event_calendar/datetime_edit',
+ array(
+ 'start_date' => $fd['start_date'],
+ 'end_date' => $fd['end_date'],
+ 'start_time' => $fd['start_time'],
+ 'end_time' => $fd['end_time'],
+ 'prefix' => $vars['prefix'],
+));
+if ($event_calendar_repeated_events == 'yes') {
+ $body .= elgg_view('event_calendar/repeat_form_element',$vars);
+}
+
+$body .= elgg_view('event_calendar/reminder_section',$vars);
+$body .= '</div>';
+
+echo $body;
diff --git a/views/default/event_calendar/share_section.php b/views/default/event_calendar/share_section.php
new file mode 100644
index 000000000..134f07656
--- /dev/null
+++ b/views/default/event_calendar/share_section.php
@@ -0,0 +1,26 @@
+<?php
+$fd = $vars['form_data'];
+$event_calendar_hide_access = elgg_get_plugin_setting('hide_access', 'event_calendar');
+$body = '<div class="event-calendar-edit-form-block event-calendar-edit-form-share-block">';
+$body .= '<h2>'.elgg_echo('event_calendar:permissions:header').'</h2>';
+if($event_calendar_hide_access == 'yes') {
+ $event_calendar_default_access = elgg_get_plugin_setting('default_access', 'event_calendar');
+ if($event_calendar_default_access) {
+ $body .= elgg_view("input/hidden",array('name' => 'access_id','value'=>$event_calendar_default_access));
+ } else {
+ $body .= elgg_view("input/hidden",array('name' => 'access_id','value'=>ACCESS_DEFAULT));
+ }
+} else {
+ $body .= '<p><label>'.elgg_echo('event_calendar:read_access').'</label>';
+ $body .= elgg_view("input/access",array('name' => 'access_id','value'=>$fd['access_id']));
+ $body .= '</p>';
+}
+if (elgg_plugin_exists('entity_admins')) {
+ $body .= elgg_echo('event_calendar:share_ownership:label');
+ $body .= '<br />';
+ $body .= elgg_echo('event_calendar:share_ownership:description');
+ $body .= elgg_view('input/entity_admins_dropdown',array('entity'=>$vars['event']));
+}
+$body .= '</div>';
+
+echo $body;