@7365admin1/layer-common 1.10.8 → 1.10.10
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 +12 -0
- package/components/AccessCardAddForm.vue +1 -1
- package/components/AccessCardAssignToUnitForm.vue +1 -1
- package/components/AccessManagement.vue +1 -1
- package/components/BulletinBoardManagement.vue +18 -8
- package/components/Carousel.vue +474 -0
- package/components/DeliveryCompany.vue +240 -0
- package/components/DrawImage.vue +172 -0
- package/components/EntryPassInformation.vue +70 -10
- package/components/EquipmentItemMain.vue +9 -4
- package/components/Feedback/Form.vue +4 -4
- package/components/FeedbackMain.vue +734 -146
- package/components/FileInput.vue +289 -0
- package/components/IncidentReport/Authorities.vue +189 -151
- package/components/IncidentReport/IncidentInformation.vue +14 -10
- package/components/IncidentReport/IncidentInformationDownload.vue +212 -0
- package/components/IncidentReport/affectedEntities.vue +8 -57
- package/components/SiteSettings.vue +285 -0
- package/components/StockCard.vue +11 -7
- package/components/Tooltip/Info.vue +33 -0
- package/components/VisitorForm.vue +176 -45
- package/components/VisitorManagement.vue +23 -6
- package/composables/useAccessManagement.ts +60 -18
- package/composables/useBulletin.ts +8 -3
- package/composables/useBulletinBoardPermission.ts +48 -0
- package/composables/useCleaningPermission.ts +2 -0
- package/composables/useCommonPermission.ts +29 -1
- package/composables/useEquipmentManagement.ts +63 -0
- package/composables/useFeedback.ts +53 -21
- package/composables/useFile.ts +6 -0
- package/composables/useLocalAuth.ts +29 -1
- package/composables/useSiteSettings.ts +1 -1
- package/composables/useUploadFiles.ts +94 -0
- package/composables/useUtils.ts +152 -53
- package/composables/useVisitor.ts +9 -6
- package/constants/app.ts +12 -0
- package/nuxt.config.ts +2 -0
- package/package.json +3 -1
- package/plugins/vue-draggable-next.client.ts +5 -0
- package/types/feedback.d.ts +5 -2
- package/types/site.d.ts +2 -1
- package/types/user.d.ts +1 -0
|
@@ -13,11 +13,11 @@ export default function () {
|
|
|
13
13
|
{ label: "Drop-Off", value: "drop-off" },
|
|
14
14
|
];
|
|
15
15
|
|
|
16
|
-
const typeFieldMap: Record<TVisitorType, (keyof TVisitorPayload)[]> = {
|
|
16
|
+
const typeFieldMap: Record<TVisitorType, (keyof TVisitorPayload | 'delivery-company')[]> = {
|
|
17
17
|
guest: ['name', 'nric', 'contact', 'block', 'plateNumber', 'level', 'unit' , 'unitName', 'remarks'],
|
|
18
18
|
contractor: ['contractorType', 'name', 'nric', 'company', 'contact', 'plateNumber', 'block', 'level', 'unit', 'unitName', 'remarks'],
|
|
19
19
|
'walk-in': ['name', 'company', 'nric', 'contact', 'block', 'level', 'unit' , 'unitName', 'remarks'],
|
|
20
|
-
delivery: ['attachments', 'name', 'deliveryType', 'company', 'nric', 'contact', 'plateNumber', 'block', 'level', 'unit' , 'unitName', 'remarks'],
|
|
20
|
+
delivery: ['attachments', 'name', 'deliveryType', 'delivery-company', 'nric', 'contact', 'plateNumber', 'block', 'level', 'unit' , 'unitName', 'remarks'],
|
|
21
21
|
'pick-up': ['plateNumber', 'block', 'remarks'],
|
|
22
22
|
'drop-off': ['plateNumber', 'block', 'remarks'],
|
|
23
23
|
}
|
|
@@ -33,7 +33,7 @@ export default function () {
|
|
|
33
33
|
type GetVisitorsParams = {
|
|
34
34
|
page?: number
|
|
35
35
|
limit?: number
|
|
36
|
-
|
|
36
|
+
order?: "asc" | "desc"
|
|
37
37
|
search?: string
|
|
38
38
|
org?: string
|
|
39
39
|
site?: string
|
|
@@ -42,12 +42,13 @@ export default function () {
|
|
|
42
42
|
type?: string
|
|
43
43
|
status?: string
|
|
44
44
|
checkedOut?: boolean
|
|
45
|
+
plateNumber?: string
|
|
45
46
|
}
|
|
46
47
|
|
|
47
48
|
async function getVisitors({
|
|
48
49
|
page = 1,
|
|
49
50
|
limit = 10,
|
|
50
|
-
|
|
51
|
+
order = "desc",
|
|
51
52
|
search = "",
|
|
52
53
|
org = "",
|
|
53
54
|
site = "",
|
|
@@ -56,6 +57,7 @@ export default function () {
|
|
|
56
57
|
type = "",
|
|
57
58
|
status = "",
|
|
58
59
|
// status = "registered"
|
|
60
|
+
plateNumber = "",
|
|
59
61
|
checkedOut
|
|
60
62
|
}: GetVisitorsParams = {}) {
|
|
61
63
|
return await useNuxtApp().$api<Record<string, any>>(
|
|
@@ -65,7 +67,6 @@ export default function () {
|
|
|
65
67
|
query: {
|
|
66
68
|
page,
|
|
67
69
|
limit,
|
|
68
|
-
sort,
|
|
69
70
|
search,
|
|
70
71
|
org,
|
|
71
72
|
site,
|
|
@@ -73,7 +74,9 @@ export default function () {
|
|
|
73
74
|
dateFrom,
|
|
74
75
|
type,
|
|
75
76
|
status,
|
|
76
|
-
checkedOut
|
|
77
|
+
checkedOut,
|
|
78
|
+
plateNumber,
|
|
79
|
+
order
|
|
77
80
|
},
|
|
78
81
|
}
|
|
79
82
|
);
|
package/constants/app.ts
ADDED
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export const APP_CONSTANTS = {
|
|
2
|
+
PROPERTY_MANAGEMENT: "property_management_agency",
|
|
3
|
+
HYGIENE: "cleaning_services",
|
|
4
|
+
SECURITY: "security_agency",
|
|
5
|
+
MECHANICAL_ELECTRICAL: "mechanical_electrical",
|
|
6
|
+
RESIDENT: "resident",
|
|
7
|
+
LANDSCAPING: "landscaping_services",
|
|
8
|
+
PEST_CONTROL: "pest_control_services",
|
|
9
|
+
POOL_MAINTENANCE: "pool_maintenance_services"
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
}
|
package/nuxt.config.ts
CHANGED
|
@@ -17,6 +17,8 @@ export default defineNuxtConfig({
|
|
|
17
17
|
APP: (process.env.APP as string) ?? "App",
|
|
18
18
|
API_DO_STORAGE_ENDPOINT:
|
|
19
19
|
(process.env.API_DO_STORAGE_ENDPOINT as string) ?? "",
|
|
20
|
+
API_DO_STORAGE_ENDPOINT_ANPR:
|
|
21
|
+
(process.env.API_DO_STORAGE_ENDPOINT_ANPR as string) ?? "",
|
|
20
22
|
APP_NAME: (process.env.APP_NAME as string) ?? "App",
|
|
21
23
|
APP_NAME_ROUTE: (process.env.APP_NAME_ROUTE as string) ?? "index",
|
|
22
24
|
APP_MAIN: (process.env.APP_MAIN as string) ?? "",
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@7365admin1/layer-common",
|
|
3
3
|
"license": "MIT",
|
|
4
4
|
"type": "module",
|
|
5
|
-
"version": "1.10.
|
|
5
|
+
"version": "1.10.10",
|
|
6
6
|
"author": "7365admin1",
|
|
7
7
|
"main": "./nuxt.config.ts",
|
|
8
8
|
"publishConfig": {
|
|
@@ -34,9 +34,11 @@
|
|
|
34
34
|
"@types/qrcode": "^1.5.6",
|
|
35
35
|
"ckeditor5": "^47.2.0",
|
|
36
36
|
"html2pdf.js": "^0.10.2",
|
|
37
|
+
"moment-timezone": "^0.6.0",
|
|
37
38
|
"qrcode": "^1.5.4",
|
|
38
39
|
"qrcode.vue": "^3.4.1",
|
|
39
40
|
"sass": "^1.80.6",
|
|
41
|
+
"vue-draggable-next": "^2.3.0",
|
|
40
42
|
"vue3-signature": "^0.2.4",
|
|
41
43
|
"zod": "^3.24.2"
|
|
42
44
|
}
|
package/types/feedback.d.ts
CHANGED
|
@@ -22,6 +22,7 @@ declare type TFeedback = {
|
|
|
22
22
|
createdBy?: string;
|
|
23
23
|
workOrderNo?: string;
|
|
24
24
|
workOrderId?: string;
|
|
25
|
+
app?: string;
|
|
25
26
|
};
|
|
26
27
|
|
|
27
28
|
declare type TFeedbackMetadata = {
|
|
@@ -38,7 +39,6 @@ declare type TFeedbackMetadata = {
|
|
|
38
39
|
declare type TFeedbackCreate = Pick<
|
|
39
40
|
TFeedback,
|
|
40
41
|
| "subject"
|
|
41
|
-
| "category"
|
|
42
42
|
| "location"
|
|
43
43
|
| "description"
|
|
44
44
|
| "attachments"
|
|
@@ -48,7 +48,10 @@ declare type TFeedbackCreate = Pick<
|
|
|
48
48
|
| "organization"
|
|
49
49
|
| "site"
|
|
50
50
|
| "createdBy"
|
|
51
|
-
|
|
51
|
+
| "app"
|
|
52
|
+
> & {
|
|
53
|
+
category?: string;
|
|
54
|
+
};
|
|
52
55
|
|
|
53
56
|
declare type TFeedbackUpdate = Pick<
|
|
54
57
|
TFeedback,
|
package/types/site.d.ts
CHANGED