aboutsummaryrefslogtreecommitdiffstats
path: root/view/tpl/events-js.tpl
blob: 7ecf2e753410af74160e933c07a404052dd217dc (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
{{$tabs}}
<div class="generic-content-wrapper-styled">
<h2>{{$title}}</h2>


<button class="btn btn-xs btn-success btn-xs pull-right" title="{{$usage}}" onclick="openClose('event-upload-form');"><i class="icon-upload"></i>&nbsp;{{$upload}}</button>

<div id="event-upload-form" style="display:none;">
    <div class="section-content-tools-wrapper">
        <form action="events" enctype="multipart/form-data" method="post" name="event-upload-form" id="event-upload-form">
            <div class="form-group">
                <input id="event-upload-choose" type="file" name="userfile" />
            </div>
            <button id="dbtn-submit" class="btn btn-primary btn-sm" type="submit" name="submit" >{{$submit}}</button>
		</form>
    </div>
</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>