improved calendar (#784)

This commit is contained in:
Kevin Papst
2019-05-19 16:16:20 +02:00
committed by GitHub
parent 1903d6fb77
commit d2ad87d09c
66 changed files with 1030 additions and 1190 deletions

View File

@@ -56,11 +56,19 @@
{% block navbar_start %}
{% if app.user is not null and is_granted('IS_AUTHENTICATED_REMEMBERED') %}
{% if is_granted('view_own_timesheet') %}
<li class="visible-xs-inline-block">
<a href="{{ path('timesheet') }}" class="ddt-large">
<i class="{{ 'timesheet'|icon }} fa-2x"></i>
</a>
</li>
{% if app.user.preferenceValue('login.initial_view') == 'calendar' %}
<li class="visible-xs-inline-block">
<a href="{{ path('calendar') }}" class="ddt-large">
<i class="{{ 'calendar'|icon }} fa-2x"></i>
</a>
</li>
{% else %}
<li class="visible-xs-inline-block">
<a href="{{ path('timesheet') }}" class="ddt-large">
<i class="{{ 'timesheet'|icon }} fa-2x"></i>
</a>
</li>
{% endif %}
{% endif %}
{% if is_granted('view_invoice') %}
<li class="visible-xs-inline-block">
@@ -176,7 +184,7 @@
{# no call to parent(), as we use a custom built for the frontend assets and don't want the default <script> #}
<script type="text/javascript">
document.addEventListener('DOMContentLoaded', function() {
window.kimai = new KimaiWebLoader(
var loader = new KimaiWebLoader(
{
locale: '{{ app.request.locale }}',
twentyFourHours: {{ 'true'|hour24('false') }}
@@ -206,6 +214,7 @@
'delete': '{{ 'action.delete' |trans }}'
}
);
window.kimai = loader.getKimai();
});
</script>
{% set event = trigger(constant('App\\Event\\ThemeEvent::JAVASCRIPT')) %}