@7365admin1/layer-common 4.190.0 → 4.190.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,13 @@
|
|
|
1
1
|
# @iservice365/layer-common
|
|
2
2
|
|
|
3
|
+
## 4.190.1
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- 1bcf138: Attendance Details popup shows whose record it is, and a record without a check-out shows "Check Out: -".
|
|
8
|
+
- 252f54d: Attendance and My Attendance show "Missed check-out" instead of "In Progress" when the API flags a check-in still open more than 24 hours later (DV-1867).
|
|
9
|
+
- f2eb2d8: Daily Checklist shows a Clear Filter button once a Start Date, End Date or Status is set; it clears all three and goes back to page 1.
|
|
10
|
+
|
|
3
11
|
## 4.190.0
|
|
4
12
|
|
|
5
13
|
### Minor Changes
|
|
@@ -4174,11 +4182,11 @@ Monthly report: a month that had patrols opens the list of that month's patrol r
|
|
|
4174
4182
|
`utils/console-tier.ts` + `composables/useConsoleTier.ts` mirror the server's
|
|
4175
4183
|
own rule from two endpoints the console already calls, unprojected:
|
|
4176
4184
|
|
|
4177
|
-
|
|
4178
|
-
|
|
4185
|
+
GET /api/members/user/:user/app/admin the Seven365 staff membership
|
|
4186
|
+
GET /api/roles/id/:role that membership's role document
|
|
4179
4187
|
|
|
4180
|
-
|
|
4181
|
-
|
|
4188
|
+
owner = member.type === "admin" && role.type === "admin" && role.default === true
|
|
4189
|
+
staff = member.type === "admin" && role.type === "admin"
|
|
4182
4190
|
|
|
4183
4191
|
`role.default` is the marker because it is the only property of a platform
|
|
4184
4192
|
staff role no API caller can set - `role.controller.ts` validates create and
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<v-dialog
|
|
3
3
|
v-model="showDialog"
|
|
4
|
-
|
|
4
|
+
max-width="900"
|
|
5
5
|
persistent
|
|
6
6
|
>
|
|
7
7
|
<!-- The card wears `.screen-modal` (16px corner, `--card`, the modal
|
|
@@ -31,7 +31,11 @@
|
|
|
31
31
|
</div>
|
|
32
32
|
</v-alert>
|
|
33
33
|
<v-row v-if="attendance" dense>
|
|
34
|
-
<v-col
|
|
34
|
+
<v-col v-if="!attendance.isProxy" cols="12" class="mb-4">
|
|
35
|
+
<InputLabel :title="workerTerm" />
|
|
36
|
+
<div class="att-dlg__time">{{ attendance.userName || "-" }}</div>
|
|
37
|
+
</v-col>
|
|
38
|
+
<v-col cols="6">
|
|
35
39
|
<v-row dense>
|
|
36
40
|
<v-col cols="12" class="mb-1">
|
|
37
41
|
<InputLabel title="Check In" />
|
|
@@ -76,17 +80,19 @@
|
|
|
76
80
|
</v-row>
|
|
77
81
|
</v-col>
|
|
78
82
|
|
|
79
|
-
<v-col
|
|
83
|
+
<v-col cols="6">
|
|
80
84
|
<v-row dense>
|
|
81
85
|
<v-col cols="12" class="mb-1">
|
|
82
86
|
<InputLabel title="Check Out" />
|
|
83
87
|
</v-col>
|
|
84
88
|
<v-col cols="12" class="mb-1">
|
|
85
89
|
<span class="att-dlg__time">{{
|
|
86
|
-
|
|
90
|
+
attendance.checkOut?.timestamp
|
|
91
|
+
? formatDate(attendance.checkOut.timestamp)
|
|
92
|
+
: "-"
|
|
87
93
|
}}</span>
|
|
88
94
|
</v-col>
|
|
89
|
-
<v-col cols="12" class="mb-2">
|
|
95
|
+
<v-col v-if="attendance.checkOut?.timestamp" cols="12" class="mb-2">
|
|
90
96
|
<span class="screen-hint att-dlg__meta">
|
|
91
97
|
{{
|
|
92
98
|
attendance.checkOut?.location?.latitude &&
|
|
@@ -96,7 +102,7 @@
|
|
|
96
102
|
}}
|
|
97
103
|
</span>
|
|
98
104
|
</v-col>
|
|
99
|
-
<v-col cols="12">
|
|
105
|
+
<v-col v-if="attendance.checkOut?.timestamp" cols="12">
|
|
100
106
|
<div v-if="attendance.checkOut?.img" class="att-dlg__frame">
|
|
101
107
|
<v-img
|
|
102
108
|
:src="getFileUrl(attendance.checkOut.img)"
|
|
@@ -165,6 +171,7 @@ async function loadPrivatePhotos(id: string, row: Record<string, any> | null) {
|
|
|
165
171
|
}
|
|
166
172
|
}
|
|
167
173
|
const { formatDate } = useUtils();
|
|
174
|
+
const workerTerm = useWorkerTerm().one;
|
|
168
175
|
const { getFileUrl } = useFile();
|
|
169
176
|
|
|
170
177
|
const close = () => {
|
|
@@ -169,7 +169,7 @@ function calculateTotalHours(attendance: any): string {
|
|
|
169
169
|
attendance.checkOutTimestamp || attendance.checkOut?.timestamp;
|
|
170
170
|
|
|
171
171
|
if (!checkInTime) return "N/A";
|
|
172
|
-
if (!checkOutTime) return "In Progress";
|
|
172
|
+
if (!checkOutTime) return attendance.missedCheckOut ? "Missed check-out" : "In Progress";
|
|
173
173
|
|
|
174
174
|
const checkIn = new Date(checkInTime);
|
|
175
175
|
const checkOut = new Date(checkOutTime);
|
|
@@ -103,6 +103,7 @@
|
|
|
103
103
|
<v-row no-gutters class="w-100 d-flex flex-column">
|
|
104
104
|
<div class="filter-bar">
|
|
105
105
|
<InputDateTimePicker
|
|
106
|
+
:key="`start-${filterKey}`"
|
|
106
107
|
v-model:utc="startDate"
|
|
107
108
|
density="compact"
|
|
108
109
|
hide-details
|
|
@@ -110,6 +111,7 @@
|
|
|
110
111
|
placeholder="Start Date"
|
|
111
112
|
/>
|
|
112
113
|
<InputDateTimePicker
|
|
114
|
+
:key="`end-${filterKey}`"
|
|
113
115
|
v-model:utc="endDate"
|
|
114
116
|
density="compact"
|
|
115
117
|
hide-details
|
|
@@ -127,6 +129,15 @@
|
|
|
127
129
|
item-value="value"
|
|
128
130
|
label="Status"
|
|
129
131
|
/>
|
|
132
|
+
<AppButton
|
|
133
|
+
v-if="hasFilters"
|
|
134
|
+
variant="ghost"
|
|
135
|
+
icon="mdi-filter-remove-outline"
|
|
136
|
+
class="filter-bar__fit"
|
|
137
|
+
@click="clearFilters"
|
|
138
|
+
>
|
|
139
|
+
Clear Filter
|
|
140
|
+
</AppButton>
|
|
130
141
|
</div>
|
|
131
142
|
</v-row>
|
|
132
143
|
</template>
|
|
@@ -315,6 +326,19 @@ const {
|
|
|
315
326
|
}
|
|
316
327
|
);
|
|
317
328
|
|
|
329
|
+
const filterKey = ref(0);
|
|
330
|
+
const hasFilters = computed(
|
|
331
|
+
() => !!startDate.value || !!endDate.value || status.value !== "all",
|
|
332
|
+
);
|
|
333
|
+
|
|
334
|
+
function clearFilters() {
|
|
335
|
+
startDate.value = "";
|
|
336
|
+
endDate.value = "";
|
|
337
|
+
status.value = "all";
|
|
338
|
+
page.value = 1;
|
|
339
|
+
filterKey.value++;
|
|
340
|
+
}
|
|
341
|
+
|
|
318
342
|
function calculateRemainingTime(
|
|
319
343
|
closeIn: Date | string | number | null | undefined
|
|
320
344
|
) {
|
|
@@ -187,7 +187,7 @@ function calculateTotalHours(attendance: any): string {
|
|
|
187
187
|
attendance.checkOutTimestamp || attendance.checkOut?.timestamp;
|
|
188
188
|
|
|
189
189
|
if (!checkInTime) return "N/A";
|
|
190
|
-
if (!checkOutTime) return "In Progress";
|
|
190
|
+
if (!checkOutTime) return attendance.missedCheckOut ? "Missed check-out" : "In Progress";
|
|
191
191
|
|
|
192
192
|
const checkIn = new Date(checkInTime);
|
|
193
193
|
const checkOut = new Date(checkOutTime);
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@7365admin1/layer-common",
|
|
3
3
|
"license": "MIT",
|
|
4
4
|
"type": "module",
|
|
5
|
-
"version": "4.190.
|
|
5
|
+
"version": "4.190.1",
|
|
6
6
|
"author": "7365admin1",
|
|
7
7
|
"main": "./nuxt.config.ts",
|
|
8
8
|
"//files": "What a consumer extending this layer actually loads. Without this npm ships the whole working tree - the changesets, the CI workflows, the render harness in tools/ and any scratch directory that happened to exist at publish time. Nuxt resolves a layer by directory, so every runtime directory below has to stay listed; adding a new top-level runtime directory means adding it here too.",
|