[FIX] HORILLA_THEME: Fix check in button disappearing when time is disabled
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
{% load static horillafilters attendancefilters i18n %}
|
||||
|
||||
{% if request.user.employee_get %}
|
||||
{% with get_forecasted_at_work=request.user.employee_get.get_forecasted_at_work %}
|
||||
{% if request.session.selected_company == "all" or request.user.employee_get.employee_work_info.company_id.id == request.session.selected_company|default:"-1"|add:"0" %}
|
||||
@@ -24,7 +25,7 @@
|
||||
>
|
||||
<span class="date">
|
||||
<i class="fa-solid fa-right-from-bracket pe-2"></i>
|
||||
<div class="time-runner"></div>
|
||||
<div class="time-runner">{% trans "Check Out" %}</div>
|
||||
</span>
|
||||
<span class="con hr-Check-In-out-text" {% if enabled_timerunner and get_forecasted_at_work.has_attendance %} style="display:none;" {% endif %}>
|
||||
{% trans "Check Out" %}
|
||||
@@ -55,7 +56,7 @@
|
||||
>
|
||||
<span class="date">
|
||||
<i class="fa-solid fa-right-to-bracket pe-2"></i>
|
||||
<div class="at-work-seconds"></div>
|
||||
<div class="at-work-seconds">{% trans "Check In" %}</div>
|
||||
</span>
|
||||
<span class="con hr-Check-In-out-text" {% if enabled_timerunner %} style="display:none;" {% endif %}>
|
||||
{% trans "Check In" %}
|
||||
@@ -81,6 +82,7 @@
|
||||
{% endwith %}
|
||||
{% endif %}
|
||||
|
||||
{% if enabled_timerunner %}
|
||||
<script>
|
||||
var at_work_seconds = $(".at_work_seconds").data("at-work-seconds");
|
||||
var run = $(".at_work_seconds").data("run");
|
||||
@@ -117,3 +119,4 @@
|
||||
}, 1000);
|
||||
}
|
||||
</script>
|
||||
{% endif %}
|
||||
|
||||
@@ -21,18 +21,13 @@
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
<!-- Right side - Search and Actions -->
|
||||
|
||||
<div class="flex items-center gap-8">
|
||||
|
||||
<!-- Action Icons -->
|
||||
<div class="flex items-center gap-2">
|
||||
{% if "attendance"|app_installed %}
|
||||
{% if enabled_timerunner %}
|
||||
<div id="attendance-activity-container">
|
||||
{% include "attendance/components/in_out_component.html" %}
|
||||
</div>
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
<button
|
||||
class="md:block p-2 group text-primary-600 w-12 h-12 bg-primary-100 hover:bg-primary-600 rounded-full transition duration-300 flex items-center justify-center"
|
||||
|
||||
Reference in New Issue
Block a user