|
|
|
<script type="text/javascript">
|
|
|
|
<% my $url = $self->url_for('/');
|
|
|
|
$url .= ($url =~ m/\/$/) ? '' : '/'; %>
|
|
|
|
var rootUrl = '<%= $url %>';
|
|
|
|
var currentLang = '<%= $self->languages %>';
|
|
|
|
var api_key = '<%= ($self->session('key')) ? $self->session('key') : '' %>';
|
|
|
|
var page = '<%= stash('page') ? stash('page') : "" %>';
|
|
|
|
var roomName;
|
|
|
|
</script>
|
|
|
|
<%
|
|
|
|
my @js = qw(js/jquery-1.11.3.js js/bootstrap.js js/notify-combined.js js/bootstrap-switch.js js/jquery.bootpag.js js/toc.js js/bootstrap-datepicker.js);
|
|
|
|
# Load supported languages for datpicker, if they exists
|
|
|
|
foreach my $l ($self->get_supported_lang){
|
|
|
|
if (-e 'public/js/datepicker-locales/bootstrap-datepicker.' . $l . '.js'){
|
|
|
|
push @js, 'js/datepicker-locales/bootstrap-datepicker.' . $l . '.js';
|
|
|
|
}
|
|
|
|
}
|
|
|
|
push @js, 'js/vroom.js';
|
|
|
|
if (stash('page') && stash('page') eq 'room'){
|
|
|
|
push @js, qw(js/simplewebrtc.bundle.js js/jquery.browser.js js/sprintf.js js/FileSaver.js js/jquery.tinytimer.js js/etherpad.js);
|
|
|
|
}
|
|
|
|
%>
|
|
|
|
<%=js @js %>
|