aboutsummaryrefslogtreecommitdiffstats
path: root/view/tpl/events-js.tpl
diff options
context:
space:
mode:
Diffstat (limited to 'view/tpl/events-js.tpl')
-rwxr-xr-xview/tpl/events-js.tpl12
1 files changed, 11 insertions, 1 deletions
diff --git a/view/tpl/events-js.tpl b/view/tpl/events-js.tpl
index 69a248512..9812291bf 100755
--- a/view/tpl/events-js.tpl
+++ b/view/tpl/events-js.tpl
@@ -2,7 +2,17 @@
<div class="generic-content-wrapper-styled">
<h2>{{$title}}</h2>
-<div id="new-event-link"><a href="{{$new_event.0}}" >{{$new_event.1}}</a></div>
+
+<div id="export-event-link"><button class="btn btn-default btn-sm" onclick="exportDate(); return false;" >{{$export.1}}</button></div>
+<div id="new-event-link"><button class="btn btn-default btn-sm" onclick="window.location.href='{{$new_event.0}}'; return false;" >{{$new_event.1}}</button></div>
+
+<script>
+function exportDate() {
+ var moment = $('#events-calendar').fullCalendar('getDate');
+ var sT = 'events/' + moment.getFullYear() + '/' + (moment.getMonth() + 1) + '/export';
+ window.location.href=sT;
+}
+</script>
<div id="events-calendar"></div>
</div>