diff --git a/Resources/views/report_by_user.html.twig b/Resources/views/report_by_user.html.twig
index b79ec04..6023c6f 100644
--- a/Resources/views/report_by_user.html.twig
+++ b/Resources/views/report_by_user.html.twig
@@ -316,12 +316,22 @@
window.location.href = '{{ path('not_approved',{'approveId':approveId,'user':user.id,'date':current|date('Y-m-d')}) }}'.replace(/&/g,'&');
}
}
+ function denyAction() {
+ if (confirm('{{ 'label.undoMessage'|trans }}'.replace(/"/g,'"')) === true) {
+ window.location.href = '{{ path('denied',{'approveId':approveId,'user':user.id,'date':current|date('Y-m-d')}) }}'.replace(/&/g,'&');
+ }
+ }
let undoButton = document.getElementById("undoButton");
if (undoButton) {
undoButton.addEventListener("click", undoAction);
}
+ let deniedButton = document.getElementById("deniedButton");
+ if (deniedButton) {
+ deniedButton.addEventListener("click", denyAction);
+ }
+
{% endblock %}
diff --git a/Resources/views/settings_overtime_history.html.twig b/Resources/views/settings_overtime_history.html.twig
index 1cbd9e9..35db4ed 100644
--- a/Resources/views/settings_overtime_history.html.twig
+++ b/Resources/views/settings_overtime_history.html.twig
@@ -35,7 +35,7 @@
{% set deleteLinkPath = path('delete_overtime_history', {'entryId': entry.id }) %}
|
@@ -81,7 +81,7 @@
$("#deleteMessage").hide();
}
});
- });
+ });
{% endblock %}
diff --git a/Resources/views/settings_workday_history.html.twig b/Resources/views/settings_workday_history.html.twig
index fd061ad..9ac2ee4 100644
--- a/Resources/views/settings_workday_history.html.twig
+++ b/Resources/views/settings_workday_history.html.twig
@@ -56,7 +56,7 @@
{% set deleteLinkPath = path('delete_workday_history', {'entryId': entry.id }) %}
|