From 4d62184a9b98a65c78c3aac586fcda2855cf87f4 Mon Sep 17 00:00:00 2001
From: zhangwencui <1064582902@qq.com>
Date: 星期一, 02 十一月 2026 13:35:06 +0800
Subject: [PATCH] Merge branch 'master' into dev_新高电力

---
 src/pages/hrm/attendance-clock/index.vue |   27 +++++++++++++++++++++++++++
 1 files changed, 27 insertions(+), 0 deletions(-)

diff --git a/src/pages/hrm/attendance-clock/index.vue b/src/pages/hrm/attendance-clock/index.vue
index db759fd..b5872df 100644
--- a/src/pages/hrm/attendance-clock/index.vue
+++ b/src/pages/hrm/attendance-clock/index.vue
@@ -77,6 +77,10 @@
   const isInsecureH5 = computed(() => {
     // #ifdef H5
     return typeof window !== "undefined" && !window.isSecureContext;
+    // #endif
+    // #ifndef H5
+    return false;
+    // #endif
   });
   const locationStatusText = computed(() => {
     if (!locationRequired.value) return "褰撳墠瑙勫垯鏈惎鐢ㄤ綅缃檺鍒�";
@@ -228,6 +232,12 @@
       "褰撳墠鐢ㄦ埛"
   );
   const department = computed(() => status.value?.deptName || "鏈垎閰嶉儴闂�");
+  const onLeave = computed(() => status.value?.onLeave === true || record.value?.leaveFlag === true);
+  const leaveText = computed(() => {
+    const names = status.value?.leaveTypeNames || "璇峰亣";
+    const hours = Number(status.value?.leaveHours ?? record.value?.leaveHours ?? 0);
+    return hours > 0 ? `${names} ${hours.toFixed(2)} 灏忔椂` : names;
+  });
   const dateLabel = computed(() => {
     const rest =
       status.value && status.value.workDay === false
@@ -483,6 +493,10 @@
       <text class="smart-hint">{{ punch.hint }}</text>
       <text class="rule-time">鐝 {{ rule?.workStartTime || "--:--" }} - {{ rule?.workEndTime || "--:--" }}</text>
     </view>
+    <view v-if="onLeave" class="leave-alert">
+      <strong>浠婃棩宸茶鍋囷紝濡傞渶涓婄彮鍙甯告墦鍗�</strong>
+      <text>{{ leaveText }} 路 璇峰亣褰撳ぉ鎵撳崱涓嶈杩熷埌銆佹棭閫�鎴栫己鍗�</text>
+    </view>
     <!-- #ifdef H5 -->
     <view v-if="locationRequired && mapVisible"
           class="map-panel">
@@ -610,6 +624,19 @@
     align-items: center;
     padding: 38rpx 0 30rpx;
   }
+  .leave-alert {
+    display: flex;
+    flex-direction: column;
+    gap: 8rpx;
+    padding: 20rpx 24rpx;
+    margin-bottom: 20rpx;
+    color: #245a91;
+    background: #eaf4ff;
+    border: 1rpx solid #b8d8f7;
+    border-radius: 14rpx;
+  }
+  .leave-alert strong { font-size: 27rpx; }
+  .leave-alert text { color: #5d7894; font-size: 23rpx; }
   .time {
     display: block;
     font-size: 66rpx;

--
Gitblit v1.9.3