aq-fe-framework 0.1.313 → 0.1.315
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/dist/{chunk-JIPPFPV6.mjs → chunk-BSQT2XIP.mjs} +1 -1
- package/dist/{chunk-TWAQUUQZ.mjs → chunk-FUHOV7NB.mjs} +35 -6
- package/dist/{chunk-QPPD4PQX.mjs → chunk-VECMRDKG.mjs} +1 -0
- package/dist/{chunk-QPNYGFTI.mjs → chunk-YJ32RSH2.mjs} +7 -2
- package/dist/components/index.mjs +4 -4
- package/dist/core/index.mjs +2 -2
- package/dist/hooks/index.d.mts +2 -1
- package/dist/hooks/index.mjs +1 -1
- package/dist/modules-features/index.d.mts +33 -81
- package/dist/modules-features/index.mjs +584 -897
- package/dist/utils/index.d.mts +1 -1
- package/dist/utils/index.mjs +1 -1
- package/package.json +1 -1
@@ -1,3 +1,11 @@
|
|
1
|
+
import {
|
2
|
+
U0DateToDDMMYYYString,
|
3
|
+
U0MyValidateEmail,
|
4
|
+
updateEnableList,
|
5
|
+
utils_config_getBaseUrl,
|
6
|
+
utils_converter_enumToSelectOptions,
|
7
|
+
utils_file_fileToAQDocumentType
|
8
|
+
} from "../chunk-VECMRDKG.mjs";
|
1
9
|
import {
|
2
10
|
F_authenticate_Logout,
|
3
11
|
MyActionIconDelete,
|
@@ -22,20 +30,15 @@ import {
|
|
22
30
|
useS_BasicAppShell,
|
23
31
|
useS_authenticate,
|
24
32
|
utils_layout_getItemsWithoutLinks
|
25
|
-
} from "../chunk-
|
26
|
-
import
|
27
|
-
createGenericStore
|
28
|
-
} from "../chunk-Y3YGC5IH.mjs";
|
33
|
+
} from "../chunk-FUHOV7NB.mjs";
|
34
|
+
import "../chunk-5U2JSHSJ.mjs";
|
29
35
|
import {
|
30
36
|
const_object_documentTypes
|
31
37
|
} from "../chunk-GFEMKKFH.mjs";
|
32
|
-
import {
|
33
|
-
enum_emailConfigModule
|
34
|
-
} from "../chunk-VH4ZAD6M.mjs";
|
35
38
|
import {
|
36
39
|
MyButton as MyButton2,
|
37
40
|
MyTextInput as MyTextInput2
|
38
|
-
} from "../chunk-
|
41
|
+
} from "../chunk-BSQT2XIP.mjs";
|
39
42
|
import {
|
40
43
|
MyFlexColumn,
|
41
44
|
MyFlexRow
|
@@ -43,6 +46,9 @@ import {
|
|
43
46
|
import {
|
44
47
|
const_object_colors
|
45
48
|
} from "../chunk-NWBLJ3W3.mjs";
|
49
|
+
import {
|
50
|
+
enum_emailConfigModule
|
51
|
+
} from "../chunk-VH4ZAD6M.mjs";
|
46
52
|
import "../chunk-K6S7R6LU.mjs";
|
47
53
|
import {
|
48
54
|
baseAxios_default,
|
@@ -53,19 +59,13 @@ import {
|
|
53
59
|
useMyRouter,
|
54
60
|
useQ_AQ_GetAQModule,
|
55
61
|
useQ_SkillCenter_GetAll
|
56
|
-
} from "../chunk-
|
57
|
-
import {
|
58
|
-
U0DateToDDMMYYYString,
|
59
|
-
U0MyValidateEmail,
|
60
|
-
updateEnableList,
|
61
|
-
utils_config_getBaseUrl,
|
62
|
-
utils_converter_enumToSelectOptions,
|
63
|
-
utils_file_fileToAQDocumentType
|
64
|
-
} from "../chunk-QPPD4PQX.mjs";
|
65
|
-
import "../chunk-5U2JSHSJ.mjs";
|
62
|
+
} from "../chunk-YJ32RSH2.mjs";
|
66
63
|
import {
|
67
64
|
utils_notification_show
|
68
65
|
} from "../chunk-7ZCOFATU.mjs";
|
66
|
+
import {
|
67
|
+
createGenericStore
|
68
|
+
} from "../chunk-Y3YGC5IH.mjs";
|
69
69
|
import {
|
70
70
|
__objRest,
|
71
71
|
__spreadProps,
|
@@ -118,12 +118,13 @@ function F_accountManagement_ChangePermission({ user }) {
|
|
118
118
|
queryKey: [`F1_1ChangePermission`],
|
119
119
|
queryFn: async () => {
|
120
120
|
const response = await baseAxios_default.get("/Role/GetAdminRole");
|
121
|
+
if (process.env.NEXT_PUBLIC_APP_PROTOTYPE == "1") return mockData;
|
121
122
|
return response.data.data;
|
122
123
|
}
|
123
124
|
});
|
124
125
|
const mutation = useMutation({
|
125
126
|
mutationFn: async (roleIds) => {
|
126
|
-
const res = await baseAxios_default.post("/Role/AddUser?userId=" + user.id, roleIds);
|
127
|
+
const res = await baseAxios_default.post("/Role/AddUser?userId=" + (user == null ? void 0 : user.id), roleIds);
|
127
128
|
return res;
|
128
129
|
}
|
129
130
|
});
|
@@ -137,6 +138,11 @@ function F_accountManagement_ChangePermission({ user }) {
|
|
137
138
|
[]
|
138
139
|
);
|
139
140
|
function handleSave() {
|
141
|
+
if (process.env.NEXT_PUBLIC_APP_PROTOTYPE == "1") {
|
142
|
+
utils_notification_show({ crudType: "update" });
|
143
|
+
disc[1].close();
|
144
|
+
return;
|
145
|
+
}
|
140
146
|
mutation.mutate(Object.keys(rowSelection).map(Number), {
|
141
147
|
onSuccess: () => {
|
142
148
|
utils_notification_show({ crudType: "update" });
|
@@ -147,7 +153,8 @@ function F_accountManagement_ChangePermission({ user }) {
|
|
147
153
|
}
|
148
154
|
useEffect(() => {
|
149
155
|
var _a;
|
150
|
-
|
156
|
+
if ((user == null ? void 0 : user.roles) == void 0) return;
|
157
|
+
const result = (_a = user == null ? void 0 : user.roles) == null ? void 0 : _a.reduce((acc, item) => {
|
151
158
|
if (item.id !== void 0) {
|
152
159
|
acc[item.id] = true;
|
153
160
|
}
|
@@ -165,15 +172,15 @@ function F_accountManagement_ChangePermission({ user }) {
|
|
165
172
|
children: /* @__PURE__ */ jsxs(Table.Tbody, { children: [
|
166
173
|
/* @__PURE__ */ jsxs(Table.Tr, { children: [
|
167
174
|
/* @__PURE__ */ jsx(Table.Th, { w: 160, children: "H\u1ECD v\xE0 t\xEAn:" }),
|
168
|
-
/* @__PURE__ */ jsx(Table.Td, { children: user.fullName })
|
175
|
+
/* @__PURE__ */ jsx(Table.Td, { children: user == null ? void 0 : user.fullName })
|
169
176
|
] }),
|
170
177
|
/* @__PURE__ */ jsxs(Table.Tr, { children: [
|
171
178
|
/* @__PURE__ */ jsx(Table.Th, { children: "T\xEAn \u0111\u0103ng nh\u1EADp:" }),
|
172
|
-
/* @__PURE__ */ jsx(Table.Td, { children: user.userName })
|
179
|
+
/* @__PURE__ */ jsx(Table.Td, { children: user == null ? void 0 : user.userName })
|
173
180
|
] }),
|
174
181
|
/* @__PURE__ */ jsxs(Table.Tr, { children: [
|
175
182
|
/* @__PURE__ */ jsx(Table.Th, { children: "Email:" }),
|
176
|
-
/* @__PURE__ */ jsx(Table.Td, { children: user.email })
|
183
|
+
/* @__PURE__ */ jsx(Table.Td, { children: user == null ? void 0 : user.email })
|
177
184
|
] })
|
178
185
|
] })
|
179
186
|
}
|
@@ -201,12 +208,18 @@ function F_accountManagement_ChangePermission({ user }) {
|
|
201
208
|
}
|
202
209
|
},
|
203
210
|
columns: permissionColumns,
|
204
|
-
data: query.data
|
211
|
+
data: query.data || []
|
205
212
|
}
|
206
213
|
) }),
|
207
214
|
/* @__PURE__ */ jsx(Group, { justify: "flex-end", mt: 24, children: /* @__PURE__ */ jsx(Button, { onClick: handleSave, children: "L\u01B0u" }) })
|
208
215
|
] });
|
209
216
|
}
|
217
|
+
var mockData = [
|
218
|
+
{ id: 1, code: "a", name: "Gi\u1EA3ng vi\xEAn" },
|
219
|
+
{ id: 2, code: "b", name: "Student" },
|
220
|
+
{ id: 3, code: "c", name: "Faculty" },
|
221
|
+
{ id: 4, code: "d", name: "Admin" }
|
222
|
+
];
|
210
223
|
|
211
224
|
// src/modules-features/admin/core/accountManagement/F_accountManagement_Create.tsx
|
212
225
|
import { MultiSelect } from "@mantine/core";
|
@@ -294,7 +307,9 @@ function F_accountManagement_Delete({ id, code }) {
|
|
294
307
|
MyActionIconDelete,
|
295
308
|
{
|
296
309
|
contextData: code,
|
297
|
-
onSubmit:
|
310
|
+
onSubmit: () => {
|
311
|
+
return baseAxios_default.post(ENDPOINT2, { id });
|
312
|
+
}
|
298
313
|
}
|
299
314
|
);
|
300
315
|
}
|
@@ -385,10 +400,13 @@ function F_accountManagement_Read() {
|
|
385
400
|
const store = useS_accountManagement();
|
386
401
|
const AllUserQuery = useMyReactQuery({
|
387
402
|
queryKey: ["AllUserQuery", paginationState[0].pageIndex + 1, paginationState[0].pageSize],
|
388
|
-
axiosFn: async () =>
|
389
|
-
|
390
|
-
|
391
|
-
|
403
|
+
axiosFn: async () => {
|
404
|
+
return apiData_Account.getAdminAccount({
|
405
|
+
pageNumber: paginationState[0].pageIndex + 1,
|
406
|
+
pageSize: paginationState[0].pageSize
|
407
|
+
});
|
408
|
+
},
|
409
|
+
mockData: mockUserData
|
392
410
|
});
|
393
411
|
const getTotalAccount = useMyReactQuery({
|
394
412
|
queryKey: ["getTotalAccount"],
|
@@ -459,6 +477,33 @@ function F_accountManagement_Read() {
|
|
459
477
|
}
|
460
478
|
);
|
461
479
|
}
|
480
|
+
var mockUserData = [
|
481
|
+
{
|
482
|
+
userName: "nguyenvana",
|
483
|
+
fullName: "Nguy\u1EC5n V\u0103n A",
|
484
|
+
email: "vana@example.com"
|
485
|
+
},
|
486
|
+
{
|
487
|
+
userName: "tranthib",
|
488
|
+
fullName: "Tr\u1EA7n Th\u1ECB B",
|
489
|
+
email: "thib@example.com"
|
490
|
+
},
|
491
|
+
{
|
492
|
+
userName: "leminhc",
|
493
|
+
fullName: "L\xEA Minh C",
|
494
|
+
email: "minhc@example.com"
|
495
|
+
},
|
496
|
+
{
|
497
|
+
userName: "phamthid",
|
498
|
+
fullName: "Ph\u1EA1m Th\u1ECB D",
|
499
|
+
email: "thid@example.com"
|
500
|
+
},
|
501
|
+
{
|
502
|
+
userName: "doanvanh",
|
503
|
+
fullName: "Do\xE3n V\u0103n H",
|
504
|
+
email: "vanh@example.com"
|
505
|
+
}
|
506
|
+
];
|
462
507
|
|
463
508
|
// src/modules-features/admin/core/accountManagement/F_accountManagement.tsx
|
464
509
|
import { jsx as jsx6 } from "react/jsx-runtime";
|
@@ -2864,480 +2909,93 @@ function F_core64229() {
|
|
2864
2909
|
return /* @__PURE__ */ jsx52(F_core64229_Read, { emailModule: utils_converter_enumToSelectOptions(enum_emailConfigModule) });
|
2865
2910
|
}
|
2866
2911
|
|
2867
|
-
// src/modules-features/admin/core/
|
2868
|
-
import {
|
2869
|
-
|
2870
|
-
// src/modules-features/admin/core/core71678/F_core71678_Read.tsx
|
2871
|
-
import { Button as Button4, Group as Group5 } from "@mantine/core";
|
2872
|
-
import { IconShield as IconShield2 } from "@tabler/icons-react";
|
2873
|
-
import { useRouter } from "next/navigation";
|
2874
|
-
import { useMemo as useMemo13, useState as useState9 } from "react";
|
2875
|
-
|
2876
|
-
// src/modules-features/admin/core/core71678/F_core71678_ChangePermission.tsx
|
2877
|
-
import { Button as Button3, Fieldset as Fieldset2, Group as Group4, Table as Table3 } from "@mantine/core";
|
2878
|
-
import { useDisclosure as useDisclosure2 } from "@mantine/hooks";
|
2879
|
-
import { useMutation as useMutation4, useQuery as useQuery13, useQueryClient as useQueryClient2 } from "@tanstack/react-query";
|
2880
|
-
import { useEffect as useEffect8, useMemo as useMemo12, useState as useState7 } from "react";
|
2881
|
-
import { jsx as jsx53, jsxs as jsxs35 } from "react/jsx-runtime";
|
2882
|
-
function F_core71678_ChangePermission({ user }) {
|
2883
|
-
const disc = useDisclosure2();
|
2884
|
-
const queryClient = useQueryClient2();
|
2885
|
-
const [rowSelection, setRowSelection] = useState7({});
|
2886
|
-
const rowSelect = useState7();
|
2887
|
-
const query = useQuery13({
|
2888
|
-
queryKey: [`F1_1ChangePermission`],
|
2889
|
-
queryFn: async () => {
|
2890
|
-
const response = await baseAxios_default.get("/Role/GetAdminRole");
|
2891
|
-
return response.data.data;
|
2892
|
-
}
|
2893
|
-
});
|
2894
|
-
const mutation = useMutation4({
|
2895
|
-
mutationFn: async (roleIds) => {
|
2896
|
-
const res = await baseAxios_default.post("/Role/AddUser?userId=" + user.id, roleIds);
|
2897
|
-
return res;
|
2898
|
-
}
|
2899
|
-
});
|
2900
|
-
const permissionColumns = useMemo12(
|
2901
|
-
() => [
|
2902
|
-
{
|
2903
|
-
header: "Quy\u1EC1n",
|
2904
|
-
accessorKey: "name"
|
2905
|
-
}
|
2906
|
-
],
|
2907
|
-
[]
|
2908
|
-
);
|
2909
|
-
function handleSave() {
|
2910
|
-
mutation.mutate(Object.keys(rowSelection).map(Number), {
|
2911
|
-
onSuccess: () => {
|
2912
|
-
utils_notification_show({ crudType: "update" });
|
2913
|
-
disc[1].close();
|
2914
|
-
queryClient.invalidateQueries();
|
2915
|
-
}
|
2916
|
-
});
|
2917
|
-
}
|
2918
|
-
useEffect8(() => {
|
2919
|
-
var _a;
|
2920
|
-
const result = (_a = user.roles) == null ? void 0 : _a.reduce((acc, item) => {
|
2921
|
-
if (item.id !== void 0) {
|
2922
|
-
acc[item.id] = true;
|
2923
|
-
}
|
2924
|
-
return acc;
|
2925
|
-
}, {});
|
2926
|
-
setRowSelection(result);
|
2927
|
-
}, []);
|
2928
|
-
return /* @__PURE__ */ jsxs35(MyButtonModal, { modalSize: "xl", disclosure: disc, title: "Ch\u1ECDn quy\u1EC1n cho ng\u01B0\u1EDDi d\xF9ng", label: "S\u1EEDa quy\u1EC1n", children: [
|
2929
|
-
/* @__PURE__ */ jsx53(
|
2930
|
-
Table3,
|
2931
|
-
{
|
2932
|
-
w: "100%",
|
2933
|
-
variant: "vertical",
|
2934
|
-
layout: "fixed",
|
2935
|
-
children: /* @__PURE__ */ jsxs35(Table3.Tbody, { children: [
|
2936
|
-
/* @__PURE__ */ jsxs35(Table3.Tr, { children: [
|
2937
|
-
/* @__PURE__ */ jsx53(Table3.Th, { w: 160, children: "H\u1ECD v\xE0 t\xEAn:" }),
|
2938
|
-
/* @__PURE__ */ jsx53(Table3.Td, { children: user.fullName })
|
2939
|
-
] }),
|
2940
|
-
/* @__PURE__ */ jsxs35(Table3.Tr, { children: [
|
2941
|
-
/* @__PURE__ */ jsx53(Table3.Th, { children: "T\xEAn \u0111\u0103ng nh\u1EADp:" }),
|
2942
|
-
/* @__PURE__ */ jsx53(Table3.Td, { children: user.userName })
|
2943
|
-
] }),
|
2944
|
-
/* @__PURE__ */ jsxs35(Table3.Tr, { children: [
|
2945
|
-
/* @__PURE__ */ jsx53(Table3.Th, { children: "Email:" }),
|
2946
|
-
/* @__PURE__ */ jsx53(Table3.Td, { children: user.email })
|
2947
|
-
] })
|
2948
|
-
] })
|
2949
|
-
}
|
2950
|
-
),
|
2951
|
-
query.isLoading && "\u0110ang t\u1EA3i d\u1EEF li\u1EC7u...",
|
2952
|
-
query.isError && "L\u1ED7i khi t\u1EA3i d\u1EEF li\u1EC7u...",
|
2953
|
-
/* @__PURE__ */ jsx53(Fieldset2, { legend: "Ch\u1ECDn quy\u1EC1n", children: /* @__PURE__ */ jsx53(
|
2954
|
-
MyDataTable,
|
2955
|
-
{
|
2956
|
-
enableRowSelection: true,
|
2957
|
-
onRowSelectionChange: setRowSelection,
|
2958
|
-
state: { rowSelection },
|
2959
|
-
setSelectedRow: rowSelect[1],
|
2960
|
-
getRowId: (originalRow) => {
|
2961
|
-
var _a;
|
2962
|
-
return (_a = originalRow.id) == null ? void 0 : _a.toString();
|
2963
|
-
},
|
2964
|
-
initialState: {
|
2965
|
-
density: "xs",
|
2966
|
-
pagination: { pageIndex: 0, pageSize: 10 },
|
2967
|
-
columnPinning: { right: ["mrt-row-actions"] },
|
2968
|
-
columnVisibility: {
|
2969
|
-
nguoiCapNhat: false,
|
2970
|
-
ngayCapNhat: false
|
2971
|
-
}
|
2972
|
-
},
|
2973
|
-
columns: permissionColumns,
|
2974
|
-
data: query.data
|
2975
|
-
}
|
2976
|
-
) }),
|
2977
|
-
/* @__PURE__ */ jsx53(Group4, { justify: "flex-end", mt: 24, children: /* @__PURE__ */ jsx53(Button3, { onClick: handleSave, children: "L\u01B0u" }) })
|
2978
|
-
] });
|
2979
|
-
}
|
2912
|
+
// src/modules-features/admin/core/core76318/F_core76318_Read.tsx
|
2913
|
+
import { useQuery as useQuery13 } from "@tanstack/react-query";
|
2914
|
+
import { useMemo as useMemo12 } from "react";
|
2980
2915
|
|
2981
|
-
// src/modules-features/admin/core/
|
2982
|
-
import {
|
2916
|
+
// src/modules-features/admin/core/core76318/F_core76318_Create.tsx
|
2917
|
+
import { FileInput as FileInput5 } from "@mantine/core";
|
2983
2918
|
import { useForm as useForm18 } from "@mantine/form";
|
2984
|
-
|
2985
|
-
|
2986
|
-
var useStore4 = createGenericStore({
|
2987
|
-
initialState: {}
|
2988
|
-
});
|
2989
|
-
function useS_core71678() {
|
2990
|
-
const store = useStore4();
|
2991
|
-
return __spreadValues({}, store);
|
2992
|
-
}
|
2993
|
-
|
2994
|
-
// src/modules-features/admin/core/core71678/F_core71678_Create.tsx
|
2995
|
-
import { jsx as jsx54, jsxs as jsxs36 } from "react/jsx-runtime";
|
2996
|
-
var ENDPOINT4 = "/Account/create";
|
2997
|
-
function F_core71678_Create() {
|
2998
|
-
var _a, _b;
|
2999
|
-
const store = useS_core71678();
|
3000
|
-
const skillCenter_getAll_query = useQ_SkillCenter_GetAll();
|
2919
|
+
import { jsx as jsx53, jsxs as jsxs35 } from "react/jsx-runtime";
|
2920
|
+
function F_core76318_Create({ SecurityTypeId }) {
|
3001
2921
|
const form = useForm18({
|
3002
|
-
|
3003
|
-
fullName: "",
|
3004
|
-
code: "",
|
3005
|
-
userName: "",
|
3006
|
-
password: "",
|
3007
|
-
email: "",
|
3008
|
-
phoneNumber: ""
|
3009
|
-
},
|
2922
|
+
mode: "uncontrolled",
|
3010
2923
|
validate: {
|
3011
|
-
|
2924
|
+
decisionCode: (value) => value ? null : "Kh\xF4ng \u0111\u01B0\u1EE3c \u0111\u1EC3 tr\u1ED1ng",
|
2925
|
+
promulgateDate: (value) => value ? null : "Kh\xF4ng \u0111\u01B0\u1EE3c \u0111\u1EC3 tr\u1ED1ng",
|
2926
|
+
name: (value) => value ? null : "Kh\xF4ng \u0111\u01B0\u1EE3c \u0111\u1EC3 tr\u1ED1ng",
|
2927
|
+
file: (value) => value ? null : "Kh\xF4ng \u0111\u01B0\u1EE3c \u0111\u1EC3 tr\u1ED1ng"
|
3012
2928
|
}
|
3013
2929
|
});
|
3014
|
-
|
3015
|
-
|
3016
|
-
|
3017
|
-
|
3018
|
-
|
3019
|
-
|
3020
|
-
|
3021
|
-
|
3022
|
-
|
3023
|
-
|
3024
|
-
|
3025
|
-
|
3026
|
-
|
3027
|
-
|
3028
|
-
|
3029
|
-
|
3030
|
-
|
3031
|
-
|
3032
|
-
|
3033
|
-
|
3034
|
-
|
3035
|
-
|
3036
|
-
|
3037
|
-
|
3038
|
-
|
3039
|
-
|
3040
|
-
|
3041
|
-
|
3042
|
-
|
3043
|
-
|
3044
|
-
|
3045
|
-
|
3046
|
-
|
3047
|
-
|
3048
|
-
|
3049
|
-
|
3050
|
-
|
3051
|
-
|
3052
|
-
|
3053
|
-
|
3054
|
-
|
3055
|
-
|
3056
|
-
|
3057
|
-
|
3058
|
-
|
3059
|
-
})));
|
3060
|
-
},
|
3061
|
-
value: (_b = form.getValues().userSkillCenters) == null ? void 0 : _b.map((item) => {
|
3062
|
-
var _a2;
|
3063
|
-
return (_a2 = item.skillCenterId) == null ? void 0 : _a2.toString();
|
3064
|
-
})
|
3065
|
-
}
|
3066
|
-
)
|
3067
|
-
] });
|
2930
|
+
return /* @__PURE__ */ jsxs35(
|
2931
|
+
MyButtonCreate,
|
2932
|
+
{
|
2933
|
+
objectName: "v\u0103n b\u1EA3n",
|
2934
|
+
form,
|
2935
|
+
onSubmit: async (values) => {
|
2936
|
+
return await baseAxios_default.post("/Document/create", __spreadProps(__spreadValues({}, values), {
|
2937
|
+
DocumentType: SecurityTypeId,
|
2938
|
+
//1.4 Thông tin xây dựng, cải tiến, bảo trì hệ thống
|
2939
|
+
fileDetail: await utils_file_fileToAQDocumentType(values.file)
|
2940
|
+
}));
|
2941
|
+
},
|
2942
|
+
children: [
|
2943
|
+
/* @__PURE__ */ jsx53(
|
2944
|
+
MyTextInput,
|
2945
|
+
__spreadValues({
|
2946
|
+
withAsterisk: true,
|
2947
|
+
label: "S\u1ED1 quy \u0111\u1ECBnh"
|
2948
|
+
}, form.getInputProps("decisionCode"))
|
2949
|
+
),
|
2950
|
+
/* @__PURE__ */ jsx53(
|
2951
|
+
MyDateInput,
|
2952
|
+
__spreadValues({
|
2953
|
+
withAsterisk: true,
|
2954
|
+
label: "Ng\xE0y ban h\xE0nh"
|
2955
|
+
}, form.getInputProps("promulgateDate"))
|
2956
|
+
),
|
2957
|
+
/* @__PURE__ */ jsx53(
|
2958
|
+
MyTextInput,
|
2959
|
+
__spreadValues({
|
2960
|
+
withAsterisk: true,
|
2961
|
+
label: "T\xEAn t\xE0i li\u1EC7u"
|
2962
|
+
}, form.getInputProps("name"))
|
2963
|
+
),
|
2964
|
+
/* @__PURE__ */ jsx53(
|
2965
|
+
FileInput5,
|
2966
|
+
__spreadValues({
|
2967
|
+
withAsterisk: true,
|
2968
|
+
placeholder: "T\u1EA3i l\xEAn t\xE0i li\u1EC7u",
|
2969
|
+
label: "T\xE0i li\u1EC7u"
|
2970
|
+
}, form.getInputProps("file"))
|
2971
|
+
)
|
2972
|
+
]
|
2973
|
+
}
|
2974
|
+
);
|
3068
2975
|
}
|
3069
2976
|
|
3070
|
-
// src/modules-features/admin/core/
|
3071
|
-
import { jsx as
|
3072
|
-
|
3073
|
-
|
3074
|
-
|
2977
|
+
// src/modules-features/admin/core/core76318/F_core76318_Delete.tsx
|
2978
|
+
import { jsx as jsx54 } from "react/jsx-runtime";
|
2979
|
+
function F_core76318_Delete({
|
2980
|
+
id,
|
2981
|
+
contextData
|
2982
|
+
}) {
|
2983
|
+
return /* @__PURE__ */ jsx54(
|
3075
2984
|
MyActionIconDelete,
|
3076
2985
|
{
|
3077
|
-
contextData
|
3078
|
-
onSubmit:
|
2986
|
+
contextData,
|
2987
|
+
onSubmit: () => baseAxios_default.post("/Document/delete", { id })
|
3079
2988
|
}
|
3080
2989
|
);
|
3081
2990
|
}
|
3082
2991
|
|
3083
|
-
// src/modules-features/admin/core/
|
3084
|
-
import {
|
2992
|
+
// src/modules-features/admin/core/core76318/F_core76318_Update.tsx
|
2993
|
+
import { FileInput as FileInput6, TextInput } from "@mantine/core";
|
3085
2994
|
import { useForm as useForm19 } from "@mantine/form";
|
3086
|
-
import {
|
3087
|
-
|
3088
|
-
|
3089
|
-
var _a, _b, _c, _d;
|
3090
|
-
const store = useS_core71678();
|
3091
|
-
const skillCenter_getAll_query = useQ_SkillCenter_GetAll();
|
2995
|
+
import { jsx as jsx55, jsxs as jsxs36 } from "react/jsx-runtime";
|
2996
|
+
function F_core76318_Update({ values }) {
|
2997
|
+
var _a;
|
3092
2998
|
const form = useForm19({
|
3093
|
-
initialValues: __spreadProps(__spreadValues({}, user), {
|
3094
|
-
userSkillCenters: (_a = user.userSkillCenters) != null ? _a : []
|
3095
|
-
})
|
3096
|
-
});
|
3097
|
-
const [editedUserSkillCentersState, setEditedUserSkillCentersState] = useState8(
|
3098
|
-
(_b = user.userSkillCenters) != null ? _b : []
|
3099
|
-
);
|
3100
|
-
return /* @__PURE__ */ jsx56(MyActionIconUpdate, { form, onSubmit: async (values) => {
|
3101
|
-
return await baseAxios_default.post(
|
3102
|
-
"/Account/update",
|
3103
|
-
__spreadProps(__spreadValues({}, values), {
|
3104
|
-
id: values.id,
|
3105
|
-
address: "",
|
3106
|
-
concurrencyStamp: "",
|
3107
|
-
isBlocked: false,
|
3108
|
-
isEnabled: true,
|
3109
|
-
workingUnitId: null,
|
3110
|
-
userSkillCenters: editedUserSkillCentersState
|
3111
|
-
})
|
3112
|
-
);
|
3113
|
-
}, children: /* @__PURE__ */ jsxs37(MyFlexColumn, { children: [
|
3114
|
-
/* @__PURE__ */ jsx56(MyTextInput, __spreadValues({ disabled: true, label: "M\xE3 t\xE0i kho\u1EA3n" }, form.getInputProps("code"))),
|
3115
|
-
/* @__PURE__ */ jsx56(MyTextInput, __spreadValues({ disabled: true, label: "T\xEAn t\xE0i kho\u1EA3n" }, form.getInputProps("userName"))),
|
3116
|
-
/* @__PURE__ */ jsx56(MyTextInput, __spreadValues({ label: "H\u1ECD v\xE0 t\xEAn" }, form.getInputProps("fullName"))),
|
3117
|
-
/* @__PURE__ */ jsx56(MyTextInput, __spreadValues({ label: "Email" }, form.getInputProps("email"))),
|
3118
|
-
/* @__PURE__ */ jsx56(MyTextInput, __spreadValues({ label: "S\u1ED1 \u0111i\u1EC7n tho\u1EA1i" }, form.getInputProps("phoneNumber"))),
|
3119
|
-
skillCenter_getAll_query.data && store.state.isRequireSkillCenter == true && /* @__PURE__ */ jsx56(
|
3120
|
-
MultiSelect4,
|
3121
|
-
{
|
3122
|
-
label: "Trung t\xE2m k\u1EF9 n\u0103ng",
|
3123
|
-
placeholder: "Ch\u1ECDn trung t\xE2m k\u1EF9 n\u0103ng",
|
3124
|
-
data: (_c = skillCenter_getAll_query.data) == null ? void 0 : _c.map((item) => {
|
3125
|
-
var _a2;
|
3126
|
-
return {
|
3127
|
-
label: item.name,
|
3128
|
-
value: (_a2 = item.id) == null ? void 0 : _a2.toString()
|
3129
|
-
};
|
3130
|
-
}),
|
3131
|
-
value: (_d = form.getValues().userSkillCenters) == null ? void 0 : _d.map((item) => {
|
3132
|
-
var _a2;
|
3133
|
-
return (_a2 = item.skillCenterId) == null ? void 0 : _a2.toString();
|
3134
|
-
}),
|
3135
|
-
onChange: (selectedValues) => {
|
3136
|
-
const selectedIds = selectedValues.map(Number);
|
3137
|
-
form.setFieldValue("userSkillCenters", selectedValues.map((item, idx) => ({
|
3138
|
-
idField: idx.toString(),
|
3139
|
-
id: 0,
|
3140
|
-
code: "string",
|
3141
|
-
name: "string",
|
3142
|
-
concurrencyStamp: "string",
|
3143
|
-
isEnabled: true,
|
3144
|
-
skillCenterId: parseInt(item.toString())
|
3145
|
-
})));
|
3146
|
-
setEditedUserSkillCentersState(
|
3147
|
-
(prev) => updateEnableList(
|
3148
|
-
prev,
|
3149
|
-
selectedIds,
|
3150
|
-
(item) => item.skillCenterId,
|
3151
|
-
(id) => ({ id: 0, skillCenterId: id, isEnabled: true })
|
3152
|
-
)
|
3153
|
-
);
|
3154
|
-
}
|
3155
|
-
}
|
3156
|
-
)
|
3157
|
-
] }) });
|
3158
|
-
}
|
3159
|
-
|
3160
|
-
// src/modules-features/admin/core/core71678/F_core71678_Read.tsx
|
3161
|
-
import { jsx as jsx57, jsxs as jsxs38 } from "react/jsx-runtime";
|
3162
|
-
function F_core71678_Read() {
|
3163
|
-
var _a, _b, _c;
|
3164
|
-
const paginationState = useState9({ pageIndex: 0, pageSize: 10 });
|
3165
|
-
const store = useS_core71678();
|
3166
|
-
const router = useRouter();
|
3167
|
-
const AllUserQuery = useMyReactQuery({
|
3168
|
-
queryKey: ["AllUserQuery", paginationState[0].pageIndex + 1, paginationState[0].pageSize],
|
3169
|
-
axiosFn: async () => apiData_Account.getAdminAccount({
|
3170
|
-
pageNumber: paginationState[0].pageIndex + 1,
|
3171
|
-
pageSize: paginationState[0].pageSize
|
3172
|
-
})
|
3173
|
-
});
|
3174
|
-
const getTotalAccount = useMyReactQuery({
|
3175
|
-
queryKey: ["getTotalAccount"],
|
3176
|
-
axiosFn: async () => apiData_Account.getAdminAccount()
|
3177
|
-
});
|
3178
|
-
const columns = useMemo13(() => {
|
3179
|
-
var _a2;
|
3180
|
-
const baseColumns = [
|
3181
|
-
{
|
3182
|
-
header: "T\xEAn t\xE0i kho\u1EA3n",
|
3183
|
-
accessorKey: "userName"
|
3184
|
-
},
|
3185
|
-
{
|
3186
|
-
header: "H\u1ECD v\xE0 t\xEAn",
|
3187
|
-
accessorKey: "fullName"
|
3188
|
-
},
|
3189
|
-
{
|
3190
|
-
header: "Email",
|
3191
|
-
accessorKey: "email"
|
3192
|
-
},
|
3193
|
-
{
|
3194
|
-
header: "Quy\u1EC1n",
|
3195
|
-
accessorFn: (row) => /* @__PURE__ */ jsx57(F_core71678_ChangePermission, { user: row })
|
3196
|
-
}
|
3197
|
-
];
|
3198
|
-
if (((_a2 = store.state) == null ? void 0 : _a2.isRequireSkillCenter) === true) {
|
3199
|
-
baseColumns.splice(3, 0, {
|
3200
|
-
header: "Trung t\xE2m k\u1EF9 n\u0103ng",
|
3201
|
-
accessorFn: (row) => {
|
3202
|
-
var _a3;
|
3203
|
-
return (_a3 = row.userSkillCenters) == null ? void 0 : _a3.map((item) => item.name + ", ");
|
3204
|
-
}
|
3205
|
-
});
|
3206
|
-
}
|
3207
|
-
return baseColumns;
|
3208
|
-
}, [(_a = store.state) == null ? void 0 : _a.isRequireSkillCenter]);
|
3209
|
-
return /* @__PURE__ */ jsx57(
|
3210
|
-
MyDataTable,
|
3211
|
-
{
|
3212
|
-
isLoading: AllUserQuery.isLoading,
|
3213
|
-
rowCount: (_c = (_b = getTotalAccount.data) == null ? void 0 : _b.length) != null ? _c : 0,
|
3214
|
-
pagination: paginationState[0],
|
3215
|
-
onPaginationChange: paginationState[1],
|
3216
|
-
columns,
|
3217
|
-
data: AllUserQuery.data || [],
|
3218
|
-
renderTopToolbarCustomActions: () => {
|
3219
|
-
return /* @__PURE__ */ jsxs38(Group5, { children: [
|
3220
|
-
/* @__PURE__ */ jsx57(F_core71678_Create, {}),
|
3221
|
-
/* @__PURE__ */ jsx57(
|
3222
|
-
Button4,
|
3223
|
-
{
|
3224
|
-
color: "violet",
|
3225
|
-
leftSection: /* @__PURE__ */ jsx57(IconShield2, {}),
|
3226
|
-
onClick: () => {
|
3227
|
-
router.push("core47643");
|
3228
|
-
},
|
3229
|
-
children: "Danh m\u1EE5c quy\u1EC1n"
|
3230
|
-
}
|
3231
|
-
)
|
3232
|
-
] });
|
3233
|
-
},
|
3234
|
-
renderRowActions: ({ row }) => {
|
3235
|
-
return /* @__PURE__ */ jsxs38(MyCenterFull, { children: [
|
3236
|
-
/* @__PURE__ */ jsx57(F_core71678_Update, { user: row.original }),
|
3237
|
-
/* @__PURE__ */ jsx57(F_core71678_Delete, { id: row.original.id, code: row.original.code })
|
3238
|
-
] });
|
3239
|
-
}
|
3240
|
-
}
|
3241
|
-
);
|
3242
|
-
}
|
3243
|
-
|
3244
|
-
// src/modules-features/admin/core/core71678/F_core71678.tsx
|
3245
|
-
import { jsx as jsx58 } from "react/jsx-runtime";
|
3246
|
-
function F_core71678({ isRequireSkillCenter = false }) {
|
3247
|
-
const store = useS_core71678();
|
3248
|
-
useEffect9(() => {
|
3249
|
-
store.setProperty("isRequireSkillCenter", isRequireSkillCenter);
|
3250
|
-
}, []);
|
3251
|
-
return /* @__PURE__ */ jsx58(F_core71678_Read, {});
|
3252
|
-
}
|
3253
|
-
|
3254
|
-
// src/modules-features/admin/core/core76318/F_core76318_Read.tsx
|
3255
|
-
import { useQuery as useQuery14 } from "@tanstack/react-query";
|
3256
|
-
import { useMemo as useMemo14 } from "react";
|
3257
|
-
|
3258
|
-
// src/modules-features/admin/core/core76318/F_core76318_Create.tsx
|
3259
|
-
import { FileInput as FileInput5 } from "@mantine/core";
|
3260
|
-
import { useForm as useForm20 } from "@mantine/form";
|
3261
|
-
import { jsx as jsx59, jsxs as jsxs39 } from "react/jsx-runtime";
|
3262
|
-
function F_core76318_Create({ SecurityTypeId }) {
|
3263
|
-
const form = useForm20({
|
3264
|
-
mode: "uncontrolled",
|
3265
|
-
validate: {
|
3266
|
-
decisionCode: (value) => value ? null : "Kh\xF4ng \u0111\u01B0\u1EE3c \u0111\u1EC3 tr\u1ED1ng",
|
3267
|
-
promulgateDate: (value) => value ? null : "Kh\xF4ng \u0111\u01B0\u1EE3c \u0111\u1EC3 tr\u1ED1ng",
|
3268
|
-
name: (value) => value ? null : "Kh\xF4ng \u0111\u01B0\u1EE3c \u0111\u1EC3 tr\u1ED1ng",
|
3269
|
-
file: (value) => value ? null : "Kh\xF4ng \u0111\u01B0\u1EE3c \u0111\u1EC3 tr\u1ED1ng"
|
3270
|
-
}
|
3271
|
-
});
|
3272
|
-
return /* @__PURE__ */ jsxs39(
|
3273
|
-
MyButtonCreate,
|
3274
|
-
{
|
3275
|
-
objectName: "v\u0103n b\u1EA3n",
|
3276
|
-
form,
|
3277
|
-
onSubmit: async (values) => {
|
3278
|
-
return await baseAxios_default.post("/Document/create", __spreadProps(__spreadValues({}, values), {
|
3279
|
-
DocumentType: SecurityTypeId,
|
3280
|
-
//1.4 Thông tin xây dựng, cải tiến, bảo trì hệ thống
|
3281
|
-
fileDetail: await utils_file_fileToAQDocumentType(values.file)
|
3282
|
-
}));
|
3283
|
-
},
|
3284
|
-
children: [
|
3285
|
-
/* @__PURE__ */ jsx59(
|
3286
|
-
MyTextInput,
|
3287
|
-
__spreadValues({
|
3288
|
-
withAsterisk: true,
|
3289
|
-
label: "S\u1ED1 quy \u0111\u1ECBnh"
|
3290
|
-
}, form.getInputProps("decisionCode"))
|
3291
|
-
),
|
3292
|
-
/* @__PURE__ */ jsx59(
|
3293
|
-
MyDateInput,
|
3294
|
-
__spreadValues({
|
3295
|
-
withAsterisk: true,
|
3296
|
-
label: "Ng\xE0y ban h\xE0nh"
|
3297
|
-
}, form.getInputProps("promulgateDate"))
|
3298
|
-
),
|
3299
|
-
/* @__PURE__ */ jsx59(
|
3300
|
-
MyTextInput,
|
3301
|
-
__spreadValues({
|
3302
|
-
withAsterisk: true,
|
3303
|
-
label: "T\xEAn t\xE0i li\u1EC7u"
|
3304
|
-
}, form.getInputProps("name"))
|
3305
|
-
),
|
3306
|
-
/* @__PURE__ */ jsx59(
|
3307
|
-
FileInput5,
|
3308
|
-
__spreadValues({
|
3309
|
-
withAsterisk: true,
|
3310
|
-
placeholder: "T\u1EA3i l\xEAn t\xE0i li\u1EC7u",
|
3311
|
-
label: "T\xE0i li\u1EC7u"
|
3312
|
-
}, form.getInputProps("file"))
|
3313
|
-
)
|
3314
|
-
]
|
3315
|
-
}
|
3316
|
-
);
|
3317
|
-
}
|
3318
|
-
|
3319
|
-
// src/modules-features/admin/core/core76318/F_core76318_Delete.tsx
|
3320
|
-
import { jsx as jsx60 } from "react/jsx-runtime";
|
3321
|
-
function F_core76318_Delete({
|
3322
|
-
id,
|
3323
|
-
contextData
|
3324
|
-
}) {
|
3325
|
-
return /* @__PURE__ */ jsx60(
|
3326
|
-
MyActionIconDelete,
|
3327
|
-
{
|
3328
|
-
contextData,
|
3329
|
-
onSubmit: () => baseAxios_default.post("/Document/delete", { id })
|
3330
|
-
}
|
3331
|
-
);
|
3332
|
-
}
|
3333
|
-
|
3334
|
-
// src/modules-features/admin/core/core76318/F_core76318_Update.tsx
|
3335
|
-
import { FileInput as FileInput6, TextInput } from "@mantine/core";
|
3336
|
-
import { useForm as useForm21 } from "@mantine/form";
|
3337
|
-
import { jsx as jsx61, jsxs as jsxs40 } from "react/jsx-runtime";
|
3338
|
-
function F_core76318_Update({ values }) {
|
3339
|
-
var _a;
|
3340
|
-
const form = useForm21({
|
3341
2999
|
mode: "uncontrolled",
|
3342
3000
|
initialValues: __spreadProps(__spreadValues({}, values), {
|
3343
3001
|
file: new File(
|
@@ -3353,7 +3011,7 @@ function F_core76318_Update({ values }) {
|
|
3353
3011
|
file: (value) => value ? null : "Kh\xF4ng \u0111\u01B0\u1EE3c \u0111\u1EC3 tr\u1ED1ng"
|
3354
3012
|
}
|
3355
3013
|
});
|
3356
|
-
return /* @__PURE__ */
|
3014
|
+
return /* @__PURE__ */ jsxs36(
|
3357
3015
|
MyActionIconUpdate,
|
3358
3016
|
{
|
3359
3017
|
form,
|
@@ -3363,28 +3021,28 @@ function F_core76318_Update({ values }) {
|
|
3363
3021
|
}));
|
3364
3022
|
},
|
3365
3023
|
children: [
|
3366
|
-
/* @__PURE__ */
|
3024
|
+
/* @__PURE__ */ jsx55(
|
3367
3025
|
TextInput,
|
3368
3026
|
__spreadValues({
|
3369
3027
|
withAsterisk: true,
|
3370
3028
|
label: "S\u1ED1 quy \u0111\u1ECBnh"
|
3371
3029
|
}, form.getInputProps("decisionCode"))
|
3372
3030
|
),
|
3373
|
-
/* @__PURE__ */
|
3031
|
+
/* @__PURE__ */ jsx55(
|
3374
3032
|
MyDateInput,
|
3375
3033
|
__spreadValues({
|
3376
3034
|
withAsterisk: true,
|
3377
3035
|
label: "Ng\xE0y ban h\xE0nh"
|
3378
3036
|
}, form.getInputProps("promulgateDate"))
|
3379
3037
|
),
|
3380
|
-
/* @__PURE__ */
|
3038
|
+
/* @__PURE__ */ jsx55(
|
3381
3039
|
TextInput,
|
3382
3040
|
__spreadValues({
|
3383
3041
|
withAsterisk: true,
|
3384
3042
|
label: "T\xEAn t\xE0i li\u1EC7u"
|
3385
3043
|
}, form.getInputProps("name"))
|
3386
3044
|
),
|
3387
|
-
/* @__PURE__ */
|
3045
|
+
/* @__PURE__ */ jsx55(
|
3388
3046
|
FileInput6,
|
3389
3047
|
__spreadValues({
|
3390
3048
|
withAsterisk: true,
|
@@ -3397,9 +3055,9 @@ function F_core76318_Update({ values }) {
|
|
3397
3055
|
}
|
3398
3056
|
|
3399
3057
|
// src/modules-features/admin/core/core76318/F_core76318_Read.tsx
|
3400
|
-
import { jsx as
|
3058
|
+
import { jsx as jsx56, jsxs as jsxs37 } from "react/jsx-runtime";
|
3401
3059
|
function F_core76318_Read({ SecurityTypeId }) {
|
3402
|
-
const query =
|
3060
|
+
const query = useQuery13({
|
3403
3061
|
queryKey: ["F_core76318_Read"],
|
3404
3062
|
queryFn: async () => {
|
3405
3063
|
var _a;
|
@@ -3409,7 +3067,7 @@ function F_core76318_Read({ SecurityTypeId }) {
|
|
3409
3067
|
return ((_a = result.data) == null ? void 0 : _a.data) || [];
|
3410
3068
|
}
|
3411
3069
|
});
|
3412
|
-
const columns =
|
3070
|
+
const columns = useMemo12(
|
3413
3071
|
() => [
|
3414
3072
|
{
|
3415
3073
|
header: "S\u1ED1 quy \u0111\u1ECBnh",
|
@@ -3426,25 +3084,25 @@ function F_core76318_Read({ SecurityTypeId }) {
|
|
3426
3084
|
{
|
3427
3085
|
header: "File",
|
3428
3086
|
accessorFn: (row) => {
|
3429
|
-
return /* @__PURE__ */
|
3087
|
+
return /* @__PURE__ */ jsx56(MyCenterFull, { children: /* @__PURE__ */ jsx56(MyButtonViewPDF, { id: row.id }) });
|
3430
3088
|
}
|
3431
3089
|
}
|
3432
3090
|
],
|
3433
3091
|
[]
|
3434
3092
|
);
|
3435
|
-
return /* @__PURE__ */
|
3093
|
+
return /* @__PURE__ */ jsx56(
|
3436
3094
|
MyDataTable,
|
3437
3095
|
{
|
3438
3096
|
isLoading: query.isLoading,
|
3439
3097
|
isError: query.isError,
|
3440
3098
|
columns,
|
3441
3099
|
data: query.data || [],
|
3442
|
-
renderTopToolbarCustomActions: () => /* @__PURE__ */
|
3100
|
+
renderTopToolbarCustomActions: () => /* @__PURE__ */ jsx56(F_core76318_Create, { SecurityTypeId }),
|
3443
3101
|
renderRowActions: ({ row }) => {
|
3444
3102
|
var _a;
|
3445
|
-
return /* @__PURE__ */
|
3446
|
-
/* @__PURE__ */
|
3447
|
-
/* @__PURE__ */
|
3103
|
+
return /* @__PURE__ */ jsxs37(MyCenterFull, { children: [
|
3104
|
+
/* @__PURE__ */ jsx56(F_core76318_Update, { values: row.original }),
|
3105
|
+
/* @__PURE__ */ jsx56(
|
3448
3106
|
F_core76318_Delete,
|
3449
3107
|
{
|
3450
3108
|
id: row.original.id,
|
@@ -3458,23 +3116,23 @@ function F_core76318_Read({ SecurityTypeId }) {
|
|
3458
3116
|
}
|
3459
3117
|
|
3460
3118
|
// src/modules-features/admin/core/core76318/F_core76318.tsx
|
3461
|
-
import { jsx as
|
3119
|
+
import { jsx as jsx57 } from "react/jsx-runtime";
|
3462
3120
|
function F_core76318({ SecurityTypeId }) {
|
3463
|
-
return /* @__PURE__ */
|
3121
|
+
return /* @__PURE__ */ jsx57(F_core76318_Read, { SecurityTypeId });
|
3464
3122
|
}
|
3465
3123
|
|
3466
3124
|
// src/modules-features/admin/core/core83092/F_core83092.tsx
|
3467
3125
|
import { Grid as Grid4, Paper as Paper6, ScrollArea as ScrollArea4 } from "@mantine/core";
|
3468
3126
|
|
3469
3127
|
// src/modules-features/admin/core/core83092/F_core83092_ReadUser.tsx
|
3470
|
-
import { useQuery as
|
3471
|
-
import { useEffect as
|
3472
|
-
import { jsx as
|
3128
|
+
import { useQuery as useQuery14 } from "@tanstack/react-query";
|
3129
|
+
import { useEffect as useEffect8, useMemo as useMemo13, useState as useState7 } from "react";
|
3130
|
+
import { jsx as jsx58 } from "react/jsx-runtime";
|
3473
3131
|
function F_core83092_ReadUser() {
|
3474
3132
|
const store = useS_core83092();
|
3475
3133
|
const query = useQ_core83092_Account_GetAdminAccount();
|
3476
|
-
const [rowSelection, setRowSelection] =
|
3477
|
-
const columns =
|
3134
|
+
const [rowSelection, setRowSelection] = useState7({});
|
3135
|
+
const columns = useMemo13(
|
3478
3136
|
() => [
|
3479
3137
|
{
|
3480
3138
|
header: "H\u1ECD v\xE0 t\xEAn",
|
@@ -3491,17 +3149,17 @@ function F_core83092_ReadUser() {
|
|
3491
3149
|
setRowSelection({ [rowId]: true });
|
3492
3150
|
store.setProperty("roleId", parseInt(rowId));
|
3493
3151
|
};
|
3494
|
-
|
3152
|
+
useEffect8(() => {
|
3495
3153
|
if (store.state.roleId == 0) return;
|
3496
3154
|
setRowSelection({ [store.state.roleId]: true });
|
3497
3155
|
}, [store.state.roleId]);
|
3498
|
-
|
3156
|
+
useEffect8(() => {
|
3499
3157
|
if (!query.data) return;
|
3500
3158
|
store.setProperty("roleId", query.data[0].id);
|
3501
3159
|
}, [query.data]);
|
3502
3160
|
if (query.isLoading) return "Loading...";
|
3503
3161
|
if (query.isError) return "C\xF3 l\u1ED7i x\u1EA3y ra!";
|
3504
|
-
return /* @__PURE__ */
|
3162
|
+
return /* @__PURE__ */ jsx58(
|
3505
3163
|
MyDataTable,
|
3506
3164
|
{
|
3507
3165
|
columns,
|
@@ -3522,7 +3180,7 @@ function F_core83092_ReadUser() {
|
|
3522
3180
|
);
|
3523
3181
|
}
|
3524
3182
|
function useQ_core83092_Account_GetAdminAccount() {
|
3525
|
-
const query =
|
3183
|
+
const query = useQuery14({
|
3526
3184
|
queryKey: ["useQ_core83092_Account_GetAdminAccount"],
|
3527
3185
|
queryFn: async () => {
|
3528
3186
|
var _a;
|
@@ -3535,13 +3193,13 @@ function useQ_core83092_Account_GetAdminAccount() {
|
|
3535
3193
|
}
|
3536
3194
|
|
3537
3195
|
// src/modules-features/admin/core/core83092/F_core83092_Save.tsx
|
3538
|
-
import { useMutation as
|
3539
|
-
import { useEffect as
|
3540
|
-
import { jsx as
|
3196
|
+
import { useMutation as useMutation4 } from "@tanstack/react-query";
|
3197
|
+
import { useEffect as useEffect9, useState as useState8 } from "react";
|
3198
|
+
import { jsx as jsx59 } from "react/jsx-runtime";
|
3541
3199
|
function F_core83092_Save() {
|
3542
3200
|
const store = useS_core83092();
|
3543
|
-
const disable =
|
3544
|
-
const mutation =
|
3201
|
+
const disable = useState8(false);
|
3202
|
+
const mutation = useMutation4({
|
3545
3203
|
mutationFn: async (body) => {
|
3546
3204
|
const res = await baseAxios_default.put("/Role/UpdateUserPermission", body);
|
3547
3205
|
return res;
|
@@ -3559,39 +3217,39 @@ function F_core83092_Save() {
|
|
3559
3217
|
}
|
3560
3218
|
});
|
3561
3219
|
}
|
3562
|
-
|
3220
|
+
useEffect9(() => {
|
3563
3221
|
if (!store.state.rolePermissions || store.state.rolePermissions.length == 0) {
|
3564
3222
|
disable[1](true);
|
3565
3223
|
return;
|
3566
3224
|
}
|
3567
3225
|
disable[1](false);
|
3568
3226
|
}, [store.state.rolePermissions]);
|
3569
|
-
return /* @__PURE__ */
|
3227
|
+
return /* @__PURE__ */ jsx59(MyButton, { disabled: disable[0], crudType: "save", onClick: handleSave });
|
3570
3228
|
}
|
3571
3229
|
|
3572
3230
|
// src/modules-features/admin/core/core83092/F_core83092_ViewMenuPermissions.tsx
|
3573
|
-
import { Checkbox as Checkbox2, Flex as Flex2, ScrollArea as ScrollArea3, Table as
|
3231
|
+
import { Checkbox as Checkbox2, Flex as Flex2, ScrollArea as ScrollArea3, Table as Table3, Text as Text2 } from "@mantine/core";
|
3574
3232
|
import { IconEdit as IconEdit2, IconEyeUp as IconEyeUp2, IconFileExport as IconFileExport2, IconPlus as IconPlus2, IconPrinter as IconPrinter2, IconTrash as IconTrash2 } from "@tabler/icons-react";
|
3575
|
-
import { useQuery as
|
3576
|
-
import React2, { useEffect as
|
3577
|
-
import { jsx as
|
3233
|
+
import { useQuery as useQuery15 } from "@tanstack/react-query";
|
3234
|
+
import React2, { useEffect as useEffect10, useState as useState9 } from "react";
|
3235
|
+
import { jsx as jsx60, jsxs as jsxs38 } from "react/jsx-runtime";
|
3578
3236
|
var title2 = "Danh s\xE1ch ch\u1EE9c n\u0103ng";
|
3579
3237
|
function F_core83092_ViewMenuPermissions({ menuData: menuData2 }) {
|
3580
3238
|
var _a, _b;
|
3581
3239
|
const store = useS_core83092();
|
3582
3240
|
const query = useGetUserPermission2({ menuData: menuData2 });
|
3583
|
-
const list =
|
3584
|
-
|
3241
|
+
const list = useState9([]);
|
3242
|
+
useEffect10(() => {
|
3585
3243
|
list[1](groupToTwoLevels(menuData2));
|
3586
3244
|
}, []);
|
3587
|
-
|
3245
|
+
useEffect10(() => {
|
3588
3246
|
if (!query.data) return;
|
3589
3247
|
store.setProperty("rolePermissions", query.data);
|
3590
3248
|
}, [query.data]);
|
3591
3249
|
if (((_a = list[0]) == null ? void 0 : _a.length) == 0) return "\u0110ang t\u1EA3i...";
|
3592
|
-
return /* @__PURE__ */
|
3593
|
-
/* @__PURE__ */
|
3594
|
-
|
3250
|
+
return /* @__PURE__ */ jsx60(ScrollArea3.Autosize, { h: "70vh", children: /* @__PURE__ */ jsxs38(Table3, { children: [
|
3251
|
+
/* @__PURE__ */ jsx60(
|
3252
|
+
Table3.Thead,
|
3595
3253
|
{
|
3596
3254
|
bg: "light-dark(var(--mantine-color-white), var(--mantine-color-dark-8))",
|
3597
3255
|
style: {
|
@@ -3601,90 +3259,90 @@ function F_core83092_ViewMenuPermissions({ menuData: menuData2 }) {
|
|
3601
3259
|
boxShadow: "0px 4px 6px rgba(0, 0, 0, 0.1)",
|
3602
3260
|
border: "1px solid var(--mantine-color-gray-4)"
|
3603
3261
|
},
|
3604
|
-
children: /* @__PURE__ */
|
3605
|
-
/* @__PURE__ */
|
3606
|
-
/* @__PURE__ */
|
3607
|
-
/* @__PURE__ */
|
3262
|
+
children: /* @__PURE__ */ jsxs38(Table3.Tr, { children: [
|
3263
|
+
/* @__PURE__ */ jsx60(Table3.Th, { children: title2 }),
|
3264
|
+
/* @__PURE__ */ jsx60(Table3.Th, { children: /* @__PURE__ */ jsxs38(Flex2, { gap: 3, direction: "column", justify: "center", align: "center", children: [
|
3265
|
+
/* @__PURE__ */ jsx60(Checkbox2, { checked: store.isAllPermission("isRead"), onChange: (e) => {
|
3608
3266
|
store.toogleAllPermissionWithType("isRead", e.target.checked);
|
3609
3267
|
} }),
|
3610
|
-
/* @__PURE__ */
|
3268
|
+
/* @__PURE__ */ jsxs38(MyFlexRow, { gap: 3, children: [
|
3611
3269
|
"Xem",
|
3612
|
-
/* @__PURE__ */
|
3270
|
+
/* @__PURE__ */ jsx60(IconEyeUp2, { color: "gray" })
|
3613
3271
|
] })
|
3614
3272
|
] }) }),
|
3615
|
-
/* @__PURE__ */
|
3616
|
-
/* @__PURE__ */
|
3273
|
+
/* @__PURE__ */ jsx60(Table3.Th, { children: /* @__PURE__ */ jsxs38(Flex2, { gap: 3, direction: "column", justify: "center", align: "center", children: [
|
3274
|
+
/* @__PURE__ */ jsx60(Checkbox2, { checked: store.isAllPermission("isCreate"), onChange: (e) => {
|
3617
3275
|
store.toogleAllPermissionWithType("isCreate", e.target.checked);
|
3618
3276
|
} }),
|
3619
|
-
/* @__PURE__ */
|
3277
|
+
/* @__PURE__ */ jsxs38(MyFlexRow, { gap: 3, children: [
|
3620
3278
|
"Th\xEAm",
|
3621
|
-
/* @__PURE__ */
|
3279
|
+
/* @__PURE__ */ jsx60(IconPlus2, { color: "blue" })
|
3622
3280
|
] })
|
3623
3281
|
] }) }),
|
3624
|
-
/* @__PURE__ */
|
3625
|
-
/* @__PURE__ */
|
3282
|
+
/* @__PURE__ */ jsx60(Table3.Th, { children: /* @__PURE__ */ jsxs38(Flex2, { gap: 3, direction: "column", justify: "center", align: "center", children: [
|
3283
|
+
/* @__PURE__ */ jsx60(Checkbox2, { checked: store.isAllPermission("isUpdate"), onChange: (e) => {
|
3626
3284
|
store.toogleAllPermissionWithType("isUpdate", e.target.checked);
|
3627
3285
|
} }),
|
3628
|
-
/* @__PURE__ */
|
3286
|
+
/* @__PURE__ */ jsxs38(MyFlexRow, { gap: 3, children: [
|
3629
3287
|
"S\u1EEDa",
|
3630
|
-
/* @__PURE__ */
|
3288
|
+
/* @__PURE__ */ jsx60(IconEdit2, { color: "var(--mantine-color-yellow-8)" })
|
3631
3289
|
] })
|
3632
3290
|
] }) }),
|
3633
|
-
/* @__PURE__ */
|
3634
|
-
/* @__PURE__ */
|
3291
|
+
/* @__PURE__ */ jsx60(Table3.Th, { children: /* @__PURE__ */ jsxs38(Flex2, { gap: 3, direction: "column", justify: "center", align: "center", children: [
|
3292
|
+
/* @__PURE__ */ jsx60(Checkbox2, { checked: store.isAllPermission("isDelete"), onChange: (e) => {
|
3635
3293
|
store.toogleAllPermissionWithType("isDelete", e.target.checked);
|
3636
3294
|
} }),
|
3637
|
-
/* @__PURE__ */
|
3295
|
+
/* @__PURE__ */ jsxs38(MyFlexRow, { gap: 3, children: [
|
3638
3296
|
"X\xF3a",
|
3639
|
-
/* @__PURE__ */
|
3297
|
+
/* @__PURE__ */ jsx60(IconTrash2, { color: "var(--mantine-color-red-8)" })
|
3640
3298
|
] })
|
3641
3299
|
] }) }),
|
3642
|
-
/* @__PURE__ */
|
3643
|
-
/* @__PURE__ */
|
3300
|
+
/* @__PURE__ */ jsx60(Table3.Th, { children: /* @__PURE__ */ jsxs38(Flex2, { gap: 3, direction: "column", justify: "center", align: "center", children: [
|
3301
|
+
/* @__PURE__ */ jsx60(Checkbox2, { checked: store.isAllPermission("isPrint"), onChange: (e) => {
|
3644
3302
|
store.toogleAllPermissionWithType("isPrint", e.target.checked);
|
3645
3303
|
} }),
|
3646
|
-
/* @__PURE__ */
|
3304
|
+
/* @__PURE__ */ jsxs38(MyFlexRow, { gap: 3, children: [
|
3647
3305
|
"In",
|
3648
|
-
/* @__PURE__ */
|
3306
|
+
/* @__PURE__ */ jsx60(IconPrinter2, { color: "var(--mantine-color-cyan-8)" })
|
3649
3307
|
] })
|
3650
3308
|
] }) }),
|
3651
|
-
/* @__PURE__ */
|
3652
|
-
/* @__PURE__ */
|
3309
|
+
/* @__PURE__ */ jsx60(Table3.Th, { children: /* @__PURE__ */ jsxs38(Flex2, { gap: 3, direction: "column", justify: "center", align: "center", children: [
|
3310
|
+
/* @__PURE__ */ jsx60(Checkbox2, { checked: store.isAllPermission("isExport"), onChange: (e) => {
|
3653
3311
|
store.toogleAllPermissionWithType("isExport", e.target.checked);
|
3654
3312
|
} }),
|
3655
|
-
/* @__PURE__ */
|
3313
|
+
/* @__PURE__ */ jsxs38(MyFlexRow, { gap: 3, children: [
|
3656
3314
|
"Xu\u1EA5t",
|
3657
|
-
/* @__PURE__ */
|
3315
|
+
/* @__PURE__ */ jsx60(IconFileExport2, { color: "var(--mantine-color-green-8)" })
|
3658
3316
|
] })
|
3659
3317
|
] }) })
|
3660
3318
|
] })
|
3661
3319
|
}
|
3662
3320
|
),
|
3663
|
-
/* @__PURE__ */
|
3664
|
-
if (item.links == void 0) return /* @__PURE__ */
|
3665
|
-
/* @__PURE__ */
|
3666
|
-
/* @__PURE__ */
|
3667
|
-
/* @__PURE__ */
|
3668
|
-
/* @__PURE__ */
|
3669
|
-
/* @__PURE__ */
|
3670
|
-
/* @__PURE__ */
|
3671
|
-
/* @__PURE__ */
|
3321
|
+
/* @__PURE__ */ jsx60(Table3.Tbody, { bg: "light-dark(var(--mantine-color-white), var(--mantine-color-dark-8))", children: (_b = list[0]) == null ? void 0 : _b.map((item, idx) => {
|
3322
|
+
if (item.links == void 0) return /* @__PURE__ */ jsxs38(Table3.Tr, { children: [
|
3323
|
+
/* @__PURE__ */ jsx60(Table3.Td, { children: item.label }),
|
3324
|
+
/* @__PURE__ */ jsx60(Table3.Td, { children: /* @__PURE__ */ jsx60(MyCenterFull, { children: /* @__PURE__ */ jsx60(Checkbox2, {}) }) }),
|
3325
|
+
/* @__PURE__ */ jsx60(Table3.Td, { children: /* @__PURE__ */ jsx60(MyCenterFull, { children: /* @__PURE__ */ jsx60(Checkbox2, {}) }) }),
|
3326
|
+
/* @__PURE__ */ jsx60(Table3.Td, { children: /* @__PURE__ */ jsx60(MyCenterFull, { children: /* @__PURE__ */ jsx60(Checkbox2, {}) }) }),
|
3327
|
+
/* @__PURE__ */ jsx60(Table3.Td, { children: /* @__PURE__ */ jsx60(MyCenterFull, { children: /* @__PURE__ */ jsx60(Checkbox2, {}) }) }),
|
3328
|
+
/* @__PURE__ */ jsx60(Table3.Td, { children: /* @__PURE__ */ jsx60(MyCenterFull, { children: /* @__PURE__ */ jsx60(Checkbox2, {}) }) }),
|
3329
|
+
/* @__PURE__ */ jsx60(Table3.Td, { children: /* @__PURE__ */ jsx60(MyCenterFull, { children: /* @__PURE__ */ jsx60(Checkbox2, {}) }) })
|
3672
3330
|
] }, idx);
|
3673
|
-
return /* @__PURE__ */
|
3674
|
-
/* @__PURE__ */
|
3675
|
-
|
3331
|
+
return /* @__PURE__ */ jsxs38(React2.Fragment, { children: [
|
3332
|
+
/* @__PURE__ */ jsx60(Table3.Tr, { children: /* @__PURE__ */ jsx60(
|
3333
|
+
Table3.Td,
|
3676
3334
|
{
|
3677
3335
|
colSpan: 7,
|
3678
3336
|
bg: const_object_colors.mantineBackgroundBlueLight,
|
3679
|
-
children: /* @__PURE__ */
|
3337
|
+
children: /* @__PURE__ */ jsx60(Text2, { fs: "oblique", size: "sm", fw: "bold", children: item.label })
|
3680
3338
|
}
|
3681
3339
|
) }, item.label),
|
3682
3340
|
item.links.map(
|
3683
3341
|
(item2, idx2) => {
|
3684
3342
|
var _a2, _b2, _c, _d, _e, _f;
|
3685
|
-
return /* @__PURE__ */
|
3686
|
-
/* @__PURE__ */
|
3687
|
-
/* @__PURE__ */
|
3343
|
+
return /* @__PURE__ */ jsxs38(Table3.Tr, { children: [
|
3344
|
+
/* @__PURE__ */ jsx60(Table3.Td, { children: item2.label }),
|
3345
|
+
/* @__PURE__ */ jsx60(Table3.Td, { children: /* @__PURE__ */ jsx60(MyCenterFull, { children: /* @__PURE__ */ jsx60(
|
3688
3346
|
Checkbox2,
|
3689
3347
|
{
|
3690
3348
|
checked: ((_a2 = store.findByPageId(item2.pageId)) == null ? void 0 : _a2.isRead) || false,
|
@@ -3695,7 +3353,7 @@ function F_core83092_ViewMenuPermissions({ menuData: menuData2 }) {
|
|
3695
3353
|
}
|
3696
3354
|
}
|
3697
3355
|
) }) }),
|
3698
|
-
/* @__PURE__ */
|
3356
|
+
/* @__PURE__ */ jsx60(Table3.Td, { children: /* @__PURE__ */ jsx60(MyCenterFull, { children: /* @__PURE__ */ jsx60(
|
3699
3357
|
Checkbox2,
|
3700
3358
|
{
|
3701
3359
|
checked: ((_b2 = store.findByPageId(item2.pageId)) == null ? void 0 : _b2.isCreate) || false,
|
@@ -3706,7 +3364,7 @@ function F_core83092_ViewMenuPermissions({ menuData: menuData2 }) {
|
|
3706
3364
|
}
|
3707
3365
|
}
|
3708
3366
|
) }) }),
|
3709
|
-
/* @__PURE__ */
|
3367
|
+
/* @__PURE__ */ jsx60(Table3.Td, { children: /* @__PURE__ */ jsx60(MyCenterFull, { children: /* @__PURE__ */ jsx60(
|
3710
3368
|
Checkbox2,
|
3711
3369
|
{
|
3712
3370
|
checked: ((_c = store.findByPageId(item2.pageId)) == null ? void 0 : _c.isUpdate) || false,
|
@@ -3717,7 +3375,7 @@ function F_core83092_ViewMenuPermissions({ menuData: menuData2 }) {
|
|
3717
3375
|
}
|
3718
3376
|
}
|
3719
3377
|
) }) }),
|
3720
|
-
/* @__PURE__ */
|
3378
|
+
/* @__PURE__ */ jsx60(Table3.Td, { children: /* @__PURE__ */ jsx60(MyCenterFull, { children: /* @__PURE__ */ jsx60(
|
3721
3379
|
Checkbox2,
|
3722
3380
|
{
|
3723
3381
|
checked: ((_d = store.findByPageId(item2.pageId)) == null ? void 0 : _d.isDelete) || false,
|
@@ -3728,7 +3386,7 @@ function F_core83092_ViewMenuPermissions({ menuData: menuData2 }) {
|
|
3728
3386
|
}
|
3729
3387
|
}
|
3730
3388
|
) }) }),
|
3731
|
-
/* @__PURE__ */
|
3389
|
+
/* @__PURE__ */ jsx60(Table3.Td, { children: /* @__PURE__ */ jsx60(MyCenterFull, { children: /* @__PURE__ */ jsx60(
|
3732
3390
|
Checkbox2,
|
3733
3391
|
{
|
3734
3392
|
checked: ((_e = store.findByPageId(item2.pageId)) == null ? void 0 : _e.isPrint) || false,
|
@@ -3739,7 +3397,7 @@ function F_core83092_ViewMenuPermissions({ menuData: menuData2 }) {
|
|
3739
3397
|
}
|
3740
3398
|
}
|
3741
3399
|
) }) }),
|
3742
|
-
/* @__PURE__ */
|
3400
|
+
/* @__PURE__ */ jsx60(Table3.Td, { children: /* @__PURE__ */ jsx60(MyCenterFull, { children: /* @__PURE__ */ jsx60(
|
3743
3401
|
Checkbox2,
|
3744
3402
|
{
|
3745
3403
|
checked: ((_f = store.findByPageId(item2.pageId)) == null ? void 0 : _f.isExport) || false,
|
@@ -3759,7 +3417,7 @@ function F_core83092_ViewMenuPermissions({ menuData: menuData2 }) {
|
|
3759
3417
|
}
|
3760
3418
|
function useGetUserPermission2({ menuData: menuData2 }) {
|
3761
3419
|
const store = useS_core83092();
|
3762
|
-
const query =
|
3420
|
+
const query = useQuery15({
|
3763
3421
|
queryKey: ["F_7p4mh9d75x_AuthorizationTable", store.state.roleId],
|
3764
3422
|
queryFn: async () => {
|
3765
3423
|
const result = await baseAxios_default.get("/Role/GetUserPermission?userId=" + store.state.roleId);
|
@@ -3795,13 +3453,13 @@ function useGetUserPermission2({ menuData: menuData2 }) {
|
|
3795
3453
|
}
|
3796
3454
|
|
3797
3455
|
// src/modules-features/admin/core/core83092/F_core83092.tsx
|
3798
|
-
import { jsx as
|
3456
|
+
import { jsx as jsx61, jsxs as jsxs39 } from "react/jsx-runtime";
|
3799
3457
|
function F_core83092({ menuData: menuData2 }) {
|
3800
|
-
return /* @__PURE__ */
|
3801
|
-
/* @__PURE__ */
|
3802
|
-
/* @__PURE__ */
|
3803
|
-
/* @__PURE__ */
|
3804
|
-
/* @__PURE__ */
|
3458
|
+
return /* @__PURE__ */ jsxs39(Grid4, { children: [
|
3459
|
+
/* @__PURE__ */ jsx61(Grid4.Col, { span: { base: 12, sm: 5 }, children: /* @__PURE__ */ jsx61(ScrollArea4.Autosize, { children: /* @__PURE__ */ jsx61(F_core83092_ReadUser, {}) }) }),
|
3460
|
+
/* @__PURE__ */ jsx61(Grid4.Col, { span: { base: 12, sm: 7 }, children: /* @__PURE__ */ jsxs39(MyFlexColumn, { h: "80vh", flex: 1, children: [
|
3461
|
+
/* @__PURE__ */ jsx61(ScrollArea4.Autosize, { h: "100%", children: /* @__PURE__ */ jsx61(Paper6, { p: "md", bg: const_object_colors.mantineBackgroundSecondary, children: /* @__PURE__ */ jsx61(F_core83092_ViewMenuPermissions, { menuData: menuData2 }) }) }),
|
3462
|
+
/* @__PURE__ */ jsx61(F_core83092_Save, {})
|
3805
3463
|
] }) })
|
3806
3464
|
] });
|
3807
3465
|
}
|
@@ -3810,10 +3468,10 @@ function F_core83092({ menuData: menuData2 }) {
|
|
3810
3468
|
import { Paper as Paper7, Space as Space4 } from "@mantine/core";
|
3811
3469
|
|
3812
3470
|
// src/modules-features/admin/core/formTemplateDocs/F_formTemplateDocs_Create.tsx
|
3813
|
-
import { useForm as
|
3814
|
-
import { jsx as
|
3471
|
+
import { useForm as useForm20 } from "@mantine/form";
|
3472
|
+
import { jsx as jsx62, jsxs as jsxs40 } from "react/jsx-runtime";
|
3815
3473
|
function F_formTemplateDocs_Create({ FormTypeId }) {
|
3816
|
-
const form =
|
3474
|
+
const form = useForm20({
|
3817
3475
|
mode: "uncontrolled",
|
3818
3476
|
validate: {
|
3819
3477
|
decisionCode: (value) => value ? null : "S\u1ED1 quy \u0111\u1ECBnh kh\xF4ng \u0111\u01B0\u1EE3c \u0111\u1EC3 tr\u1ED1ng",
|
@@ -3823,7 +3481,7 @@ function F_formTemplateDocs_Create({ FormTypeId }) {
|
|
3823
3481
|
file: (value) => value ? null : "T\u1EC7p \u0111\xEDnh k\xE8m kh\xF4ng \u0111\u01B0\u1EE3c \u0111\u1EC3 tr\u1ED1ng"
|
3824
3482
|
}
|
3825
3483
|
});
|
3826
|
-
return /* @__PURE__ */
|
3484
|
+
return /* @__PURE__ */ jsxs40(
|
3827
3485
|
MyButtonCreate,
|
3828
3486
|
{
|
3829
3487
|
objectName: "V\u0103n b\u1EA3n quy \u0111\u1ECBnh t\u1ED5 ch\u1EE9c",
|
@@ -3835,28 +3493,28 @@ function F_formTemplateDocs_Create({ FormTypeId }) {
|
|
3835
3493
|
}));
|
3836
3494
|
},
|
3837
3495
|
children: [
|
3838
|
-
/* @__PURE__ */
|
3496
|
+
/* @__PURE__ */ jsx62(
|
3839
3497
|
MyTextInput,
|
3840
3498
|
__spreadValues({
|
3841
3499
|
withAsterisk: true,
|
3842
3500
|
label: "S\u1ED1 quy \u0111\u1ECBnh"
|
3843
3501
|
}, form.getInputProps("decisionCode"))
|
3844
3502
|
),
|
3845
|
-
/* @__PURE__ */
|
3503
|
+
/* @__PURE__ */ jsx62(
|
3846
3504
|
MyDateInput,
|
3847
3505
|
__spreadValues({
|
3848
3506
|
withAsterisk: true,
|
3849
3507
|
label: "Ng\xE0y ban h\xE0nh"
|
3850
3508
|
}, form.getInputProps("promulgateDate"))
|
3851
3509
|
),
|
3852
|
-
/* @__PURE__ */
|
3510
|
+
/* @__PURE__ */ jsx62(
|
3853
3511
|
MyTextInput,
|
3854
3512
|
__spreadValues({
|
3855
3513
|
withAsterisk: true,
|
3856
3514
|
label: "T\xEAn t\xE0i li\u1EC7u"
|
3857
3515
|
}, form.getInputProps("name"))
|
3858
3516
|
),
|
3859
|
-
/* @__PURE__ */
|
3517
|
+
/* @__PURE__ */ jsx62(
|
3860
3518
|
F_core18256_Select,
|
3861
3519
|
__spreadValues({
|
3862
3520
|
withAsterisk: true,
|
@@ -3864,14 +3522,14 @@ function F_formTemplateDocs_Create({ FormTypeId }) {
|
|
3864
3522
|
documentTypeId: FormTypeId
|
3865
3523
|
}, form.getInputProps("documentAttributeId"))
|
3866
3524
|
),
|
3867
|
-
/* @__PURE__ */
|
3525
|
+
/* @__PURE__ */ jsx62(
|
3868
3526
|
MyFileInput,
|
3869
3527
|
__spreadValues({
|
3870
3528
|
withAsterisk: true,
|
3871
3529
|
label: "V\u0103n b\u1EA3n"
|
3872
3530
|
}, form.getInputProps("file"))
|
3873
3531
|
),
|
3874
|
-
/* @__PURE__ */
|
3532
|
+
/* @__PURE__ */ jsx62(
|
3875
3533
|
MyNumberInput,
|
3876
3534
|
__spreadValues({
|
3877
3535
|
label: "Th\u1EE9 t\u1EF1 hi\u1EC3n th\u1ECB tr\xEAn danh s\xE1ch"
|
@@ -3884,17 +3542,17 @@ function F_formTemplateDocs_Create({ FormTypeId }) {
|
|
3884
3542
|
|
3885
3543
|
// src/modules-features/admin/core/formTemplateDocs/F_formTemplateDocs_Read.tsx
|
3886
3544
|
import { Accordion as Accordion4, Alert as Alert4, Blockquote as Blockquote4, Skeleton as Skeleton4 } from "@mantine/core";
|
3887
|
-
import { useQuery as
|
3888
|
-
import { useMemo as
|
3545
|
+
import { useQuery as useQuery16 } from "@tanstack/react-query";
|
3546
|
+
import { useMemo as useMemo14 } from "react";
|
3889
3547
|
import { IconBug as IconBug4 } from "@tabler/icons-react";
|
3890
3548
|
|
3891
3549
|
// src/modules-features/admin/core/formTemplateDocs/F_formTemplateDocs_Delete.tsx
|
3892
|
-
import { jsx as
|
3550
|
+
import { jsx as jsx63 } from "react/jsx-runtime";
|
3893
3551
|
function F_formTemplateDocs_Delete({
|
3894
3552
|
id,
|
3895
3553
|
contextData
|
3896
3554
|
}) {
|
3897
|
-
return /* @__PURE__ */
|
3555
|
+
return /* @__PURE__ */ jsx63(
|
3898
3556
|
MyActionIconDelete,
|
3899
3557
|
{
|
3900
3558
|
contextData,
|
@@ -3904,14 +3562,14 @@ function F_formTemplateDocs_Delete({
|
|
3904
3562
|
}
|
3905
3563
|
|
3906
3564
|
// src/modules-features/admin/core/formTemplateDocs/F_formTemplateDocs_Update.tsx
|
3907
|
-
import { useForm as
|
3908
|
-
import { jsx as
|
3565
|
+
import { useForm as useForm21 } from "@mantine/form";
|
3566
|
+
import { jsx as jsx64, jsxs as jsxs41 } from "react/jsx-runtime";
|
3909
3567
|
function F_formTemplateDocs_Update({
|
3910
3568
|
values,
|
3911
3569
|
FormTypeId
|
3912
3570
|
}) {
|
3913
3571
|
var _a;
|
3914
|
-
const form =
|
3572
|
+
const form = useForm21({
|
3915
3573
|
initialValues: __spreadProps(__spreadValues({}, values), {
|
3916
3574
|
file: new File(
|
3917
3575
|
[],
|
@@ -3927,7 +3585,7 @@ function F_formTemplateDocs_Update({
|
|
3927
3585
|
file: (value) => value ? null : "T\u1EC7p \u0111\xEDnh k\xE8m kh\xF4ng \u0111\u01B0\u1EE3c \u0111\u1EC3 tr\u1ED1ng"
|
3928
3586
|
}
|
3929
3587
|
});
|
3930
|
-
return /* @__PURE__ */
|
3588
|
+
return /* @__PURE__ */ jsxs41(
|
3931
3589
|
MyActionIconUpdate,
|
3932
3590
|
{
|
3933
3591
|
form,
|
@@ -3937,28 +3595,28 @@ function F_formTemplateDocs_Update({
|
|
3937
3595
|
}));
|
3938
3596
|
},
|
3939
3597
|
children: [
|
3940
|
-
/* @__PURE__ */
|
3598
|
+
/* @__PURE__ */ jsx64(
|
3941
3599
|
MyTextInput,
|
3942
3600
|
__spreadValues({
|
3943
3601
|
withAsterisk: true,
|
3944
3602
|
label: "S\u1ED1 quy \u0111\u1ECBnh"
|
3945
3603
|
}, form.getInputProps("decisionCode"))
|
3946
3604
|
),
|
3947
|
-
/* @__PURE__ */
|
3605
|
+
/* @__PURE__ */ jsx64(
|
3948
3606
|
MyDateInput,
|
3949
3607
|
__spreadValues({
|
3950
3608
|
withAsterisk: true,
|
3951
3609
|
label: "Ng\xE0y ban h\xE0nh"
|
3952
3610
|
}, form.getInputProps("promulgateDate"))
|
3953
3611
|
),
|
3954
|
-
/* @__PURE__ */
|
3612
|
+
/* @__PURE__ */ jsx64(
|
3955
3613
|
MyTextInput,
|
3956
3614
|
__spreadValues({
|
3957
3615
|
withAsterisk: true,
|
3958
3616
|
label: "T\xEAn t\xE0i li\u1EC7u"
|
3959
3617
|
}, form.getInputProps("name"))
|
3960
3618
|
),
|
3961
|
-
/* @__PURE__ */
|
3619
|
+
/* @__PURE__ */ jsx64(
|
3962
3620
|
F_core18256_Select,
|
3963
3621
|
__spreadValues({
|
3964
3622
|
withAsterisk: true,
|
@@ -3966,14 +3624,14 @@ function F_formTemplateDocs_Update({
|
|
3966
3624
|
documentTypeId: FormTypeId
|
3967
3625
|
}, form.getInputProps("documentAttributeId"))
|
3968
3626
|
),
|
3969
|
-
/* @__PURE__ */
|
3627
|
+
/* @__PURE__ */ jsx64(
|
3970
3628
|
MyFileInput,
|
3971
3629
|
__spreadValues({
|
3972
3630
|
withAsterisk: true,
|
3973
3631
|
label: "V\u0103n b\u1EA3n"
|
3974
3632
|
}, form.getInputProps("file"))
|
3975
3633
|
),
|
3976
|
-
/* @__PURE__ */
|
3634
|
+
/* @__PURE__ */ jsx64(
|
3977
3635
|
MyNumberInput,
|
3978
3636
|
__spreadValues({
|
3979
3637
|
label: "Th\u1EE9 t\u1EF1 hi\u1EC3n th\u1ECB tr\xEAn danh s\xE1ch"
|
@@ -3985,10 +3643,10 @@ function F_formTemplateDocs_Update({
|
|
3985
3643
|
}
|
3986
3644
|
|
3987
3645
|
// src/modules-features/admin/core/formTemplateDocs/F_formTemplateDocs_Read.tsx
|
3988
|
-
import { jsx as
|
3646
|
+
import { jsx as jsx65, jsxs as jsxs42 } from "react/jsx-runtime";
|
3989
3647
|
function F_formTemplateDocs_Read({ FormTypeId }) {
|
3990
3648
|
var _a, _b, _c;
|
3991
|
-
const documentAttributeQuery =
|
3649
|
+
const documentAttributeQuery = useQuery16({
|
3992
3650
|
queryKey: ["F_formTemplateDocs_Read", FormTypeId],
|
3993
3651
|
queryFn: async () => {
|
3994
3652
|
var _a2;
|
@@ -3999,10 +3657,10 @@ function F_formTemplateDocs_Read({ FormTypeId }) {
|
|
3999
3657
|
}
|
4000
3658
|
});
|
4001
3659
|
if (((_a = documentAttributeQuery.data) == null ? void 0 : _a.length) == 0)
|
4002
|
-
return /* @__PURE__ */
|
3660
|
+
return /* @__PURE__ */ jsx65(Blockquote4, { color: "yellow", children: "Ch\u01B0a c\xF3 lo\u1EA1i v\u0103n b\u1EA3n" });
|
4003
3661
|
if (documentAttributeQuery.isError)
|
4004
|
-
return /* @__PURE__ */
|
4005
|
-
return /* @__PURE__ */
|
3662
|
+
return /* @__PURE__ */ jsx65(Alert4, { icon: /* @__PURE__ */ jsx65(IconBug4, {}), color: "red", title: "C\xF3 l\u1ED7i x\u1EA3y ra!", m: "md" });
|
3663
|
+
return /* @__PURE__ */ jsx65(Skeleton4, { h: 500, visible: documentAttributeQuery.isLoading, children: /* @__PURE__ */ jsx65(MyFlexColumn, { children: /* @__PURE__ */ jsx65(
|
4006
3664
|
Accordion4,
|
4007
3665
|
{
|
4008
3666
|
variant: "contained",
|
@@ -4013,7 +3671,7 @@ function F_formTemplateDocs_Read({ FormTypeId }) {
|
|
4013
3671
|
}
|
4014
3672
|
),
|
4015
3673
|
multiple: true,
|
4016
|
-
children: (_c = documentAttributeQuery.data) == null ? void 0 : _c.map((item, idx) => /* @__PURE__ */
|
3674
|
+
children: (_c = documentAttributeQuery.data) == null ? void 0 : _c.map((item, idx) => /* @__PURE__ */ jsx65(
|
4017
3675
|
SubRead4,
|
4018
3676
|
{
|
4019
3677
|
name: item.name,
|
@@ -4030,7 +3688,7 @@ function SubRead4({
|
|
4030
3688
|
documentType,
|
4031
3689
|
FormTypeId
|
4032
3690
|
}) {
|
4033
|
-
const documentQuery =
|
3691
|
+
const documentQuery = useQuery16({
|
4034
3692
|
queryKey: ["SF2_3Read" + documentType],
|
4035
3693
|
queryFn: async () => {
|
4036
3694
|
const result = await baseAxios_default.get(
|
@@ -4039,7 +3697,7 @@ function SubRead4({
|
|
4039
3697
|
return result.data.data;
|
4040
3698
|
}
|
4041
3699
|
});
|
4042
|
-
const columns =
|
3700
|
+
const columns = useMemo14(
|
4043
3701
|
() => [
|
4044
3702
|
{
|
4045
3703
|
header: "S\u1ED1 quy \u0111\u1ECBnh",
|
@@ -4056,7 +3714,7 @@ function SubRead4({
|
|
4056
3714
|
{
|
4057
3715
|
header: "File",
|
4058
3716
|
accessorFn: (row) => {
|
4059
|
-
return /* @__PURE__ */
|
3717
|
+
return /* @__PURE__ */ jsx65(MyCenterFull, { children: /* @__PURE__ */ jsx65(MyButtonViewPDF, { id: row.id }) });
|
4060
3718
|
}
|
4061
3719
|
}
|
4062
3720
|
],
|
@@ -4064,24 +3722,24 @@ function SubRead4({
|
|
4064
3722
|
);
|
4065
3723
|
if (documentQuery.isLoading) return "Loading...";
|
4066
3724
|
if (documentQuery.isError) return "Error!";
|
4067
|
-
return /* @__PURE__ */
|
4068
|
-
/* @__PURE__ */
|
4069
|
-
/* @__PURE__ */
|
3725
|
+
return /* @__PURE__ */ jsxs42(Accordion4.Item, { value: documentType.toString(), children: [
|
3726
|
+
/* @__PURE__ */ jsx65(Accordion4.Control, { children: name }),
|
3727
|
+
/* @__PURE__ */ jsx65(Accordion4.Panel, { children: /* @__PURE__ */ jsx65(
|
4070
3728
|
MyDataTable,
|
4071
3729
|
{
|
4072
3730
|
isLoading: documentQuery.isLoading,
|
4073
3731
|
isError: documentQuery.isError,
|
4074
3732
|
columns,
|
4075
3733
|
data: documentQuery.data || [],
|
4076
|
-
renderRowActions: ({ row }) => /* @__PURE__ */
|
4077
|
-
/* @__PURE__ */
|
3734
|
+
renderRowActions: ({ row }) => /* @__PURE__ */ jsxs42(MyCenterFull, { children: [
|
3735
|
+
/* @__PURE__ */ jsx65(
|
4078
3736
|
F_formTemplateDocs_Update,
|
4079
3737
|
{
|
4080
3738
|
FormTypeId,
|
4081
3739
|
values: row.original
|
4082
3740
|
}
|
4083
3741
|
),
|
4084
|
-
/* @__PURE__ */
|
3742
|
+
/* @__PURE__ */ jsx65(
|
4085
3743
|
F_formTemplateDocs_Delete,
|
4086
3744
|
{
|
4087
3745
|
id: row.original.id,
|
@@ -4095,14 +3753,14 @@ function SubRead4({
|
|
4095
3753
|
}
|
4096
3754
|
|
4097
3755
|
// src/modules-features/admin/core/formTemplateDocs/F_formTemplateDocs.tsx
|
4098
|
-
import { jsx as
|
3756
|
+
import { jsx as jsx66, jsxs as jsxs43 } from "react/jsx-runtime";
|
4099
3757
|
function F_formTemplateDocs({
|
4100
3758
|
FormTypeId
|
4101
3759
|
}) {
|
4102
|
-
return /* @__PURE__ */
|
4103
|
-
/* @__PURE__ */
|
4104
|
-
/* @__PURE__ */
|
4105
|
-
/* @__PURE__ */
|
3760
|
+
return /* @__PURE__ */ jsxs43(Paper7, { p: "md", children: [
|
3761
|
+
/* @__PURE__ */ jsx66(MyFlexEnd, { children: /* @__PURE__ */ jsx66(F_formTemplateDocs_Create, { FormTypeId }) }),
|
3762
|
+
/* @__PURE__ */ jsx66(Space4, {}),
|
3763
|
+
/* @__PURE__ */ jsx66(F_formTemplateDocs_Read, { FormTypeId })
|
4106
3764
|
] });
|
4107
3765
|
}
|
4108
3766
|
|
@@ -4110,12 +3768,12 @@ function F_formTemplateDocs({
|
|
4110
3768
|
import { Paper as Paper8, Space as Space5 } from "@mantine/core";
|
4111
3769
|
|
4112
3770
|
// src/modules-features/admin/core/organizationPolicyDocs/F_organizationPolicyDocs_Create.tsx
|
4113
|
-
import { useForm as
|
4114
|
-
import { jsx as
|
3771
|
+
import { useForm as useForm22 } from "@mantine/form";
|
3772
|
+
import { jsx as jsx67, jsxs as jsxs44 } from "react/jsx-runtime";
|
4115
3773
|
function F_organizationPolicyDocs_Create({
|
4116
3774
|
RegulationsTypeId
|
4117
3775
|
}) {
|
4118
|
-
const form =
|
3776
|
+
const form = useForm22({
|
4119
3777
|
mode: "uncontrolled",
|
4120
3778
|
validate: {
|
4121
3779
|
decisionCode: (value) => value ? null : "S\u1ED1 quy \u0111\u1ECBnh kh\xF4ng \u0111\u01B0\u1EE3c \u0111\u1EC3 tr\u1ED1ng",
|
@@ -4125,7 +3783,7 @@ function F_organizationPolicyDocs_Create({
|
|
4125
3783
|
file: (value) => value ? null : "T\u1EC7p \u0111\xEDnh k\xE8m kh\xF4ng \u0111\u01B0\u1EE3c \u0111\u1EC3 tr\u1ED1ng"
|
4126
3784
|
}
|
4127
3785
|
});
|
4128
|
-
return /* @__PURE__ */
|
3786
|
+
return /* @__PURE__ */ jsxs44(
|
4129
3787
|
MyButtonCreate,
|
4130
3788
|
{
|
4131
3789
|
objectName: "V\u0103n b\u1EA3n quy \u0111\u1ECBnh t\u1ED5 ch\u1EE9c",
|
@@ -4137,28 +3795,28 @@ function F_organizationPolicyDocs_Create({
|
|
4137
3795
|
}));
|
4138
3796
|
},
|
4139
3797
|
children: [
|
4140
|
-
/* @__PURE__ */
|
3798
|
+
/* @__PURE__ */ jsx67(
|
4141
3799
|
MyTextInput,
|
4142
3800
|
__spreadValues({
|
4143
3801
|
withAsterisk: true,
|
4144
3802
|
label: "S\u1ED1 quy \u0111\u1ECBnh"
|
4145
3803
|
}, form.getInputProps("decisionCode"))
|
4146
3804
|
),
|
4147
|
-
/* @__PURE__ */
|
3805
|
+
/* @__PURE__ */ jsx67(
|
4148
3806
|
MyDateInput,
|
4149
3807
|
__spreadValues({
|
4150
3808
|
withAsterisk: true,
|
4151
3809
|
label: "Ng\xE0y ban h\xE0nh"
|
4152
3810
|
}, form.getInputProps("promulgateDate"))
|
4153
3811
|
),
|
4154
|
-
/* @__PURE__ */
|
3812
|
+
/* @__PURE__ */ jsx67(
|
4155
3813
|
MyTextInput,
|
4156
3814
|
__spreadValues({
|
4157
3815
|
withAsterisk: true,
|
4158
3816
|
label: "T\xEAn t\xE0i li\u1EC7u"
|
4159
3817
|
}, form.getInputProps("name"))
|
4160
3818
|
),
|
4161
|
-
/* @__PURE__ */
|
3819
|
+
/* @__PURE__ */ jsx67(
|
4162
3820
|
F_core18256_Select,
|
4163
3821
|
__spreadValues({
|
4164
3822
|
withAsterisk: true,
|
@@ -4166,14 +3824,14 @@ function F_organizationPolicyDocs_Create({
|
|
4166
3824
|
documentTypeId: RegulationsTypeId
|
4167
3825
|
}, form.getInputProps("documentAttributeId"))
|
4168
3826
|
),
|
4169
|
-
/* @__PURE__ */
|
3827
|
+
/* @__PURE__ */ jsx67(
|
4170
3828
|
MyFileInput,
|
4171
3829
|
__spreadValues({
|
4172
3830
|
withAsterisk: true,
|
4173
3831
|
label: "V\u0103n b\u1EA3n"
|
4174
3832
|
}, form.getInputProps("file"))
|
4175
3833
|
),
|
4176
|
-
/* @__PURE__ */
|
3834
|
+
/* @__PURE__ */ jsx67(
|
4177
3835
|
MyNumberInput,
|
4178
3836
|
__spreadValues({
|
4179
3837
|
label: "Th\u1EE9 t\u1EF1 hi\u1EC3n th\u1ECB tr\xEAn danh s\xE1ch"
|
@@ -4186,17 +3844,17 @@ function F_organizationPolicyDocs_Create({
|
|
4186
3844
|
|
4187
3845
|
// src/modules-features/admin/core/organizationPolicyDocs/F_organizationPolicyDocs_Read.tsx
|
4188
3846
|
import { Accordion as Accordion5, Alert as Alert5, Blockquote as Blockquote5, Skeleton as Skeleton5 } from "@mantine/core";
|
4189
|
-
import { useQuery as
|
3847
|
+
import { useQuery as useQuery17 } from "@tanstack/react-query";
|
4190
3848
|
import { IconBug as IconBug5 } from "@tabler/icons-react";
|
4191
|
-
import { useMemo as
|
3849
|
+
import { useMemo as useMemo15 } from "react";
|
4192
3850
|
|
4193
3851
|
// src/modules-features/admin/core/organizationPolicyDocs/F_organizationPolicyDocs_Delete.tsx
|
4194
|
-
import { jsx as
|
3852
|
+
import { jsx as jsx68 } from "react/jsx-runtime";
|
4195
3853
|
function F_organizationPolicyDocs_Delete({
|
4196
3854
|
id,
|
4197
3855
|
contextData
|
4198
3856
|
}) {
|
4199
|
-
return /* @__PURE__ */
|
3857
|
+
return /* @__PURE__ */ jsx68(
|
4200
3858
|
MyActionIconDelete,
|
4201
3859
|
{
|
4202
3860
|
contextData,
|
@@ -4206,14 +3864,14 @@ function F_organizationPolicyDocs_Delete({
|
|
4206
3864
|
}
|
4207
3865
|
|
4208
3866
|
// src/modules-features/admin/core/organizationPolicyDocs/F_organizationPolicyDocs_Update.tsx
|
4209
|
-
import { useForm as
|
4210
|
-
import { jsx as
|
3867
|
+
import { useForm as useForm23 } from "@mantine/form";
|
3868
|
+
import { jsx as jsx69, jsxs as jsxs45 } from "react/jsx-runtime";
|
4211
3869
|
function F_organizationPolicyDocs_Update({
|
4212
3870
|
values,
|
4213
3871
|
RegulationsTypeId
|
4214
3872
|
}) {
|
4215
3873
|
var _a;
|
4216
|
-
const form =
|
3874
|
+
const form = useForm23({
|
4217
3875
|
initialValues: __spreadProps(__spreadValues({}, values), {
|
4218
3876
|
file: new File(
|
4219
3877
|
[],
|
@@ -4229,7 +3887,7 @@ function F_organizationPolicyDocs_Update({
|
|
4229
3887
|
file: (value) => value ? null : "T\u1EC7p \u0111\xEDnh k\xE8m kh\xF4ng \u0111\u01B0\u1EE3c \u0111\u1EC3 tr\u1ED1ng"
|
4230
3888
|
}
|
4231
3889
|
});
|
4232
|
-
return /* @__PURE__ */
|
3890
|
+
return /* @__PURE__ */ jsxs45(
|
4233
3891
|
MyActionIconUpdate,
|
4234
3892
|
{
|
4235
3893
|
form,
|
@@ -4239,28 +3897,28 @@ function F_organizationPolicyDocs_Update({
|
|
4239
3897
|
}));
|
4240
3898
|
},
|
4241
3899
|
children: [
|
4242
|
-
/* @__PURE__ */
|
3900
|
+
/* @__PURE__ */ jsx69(
|
4243
3901
|
MyTextInput,
|
4244
3902
|
__spreadValues({
|
4245
3903
|
withAsterisk: true,
|
4246
3904
|
label: "S\u1ED1 quy \u0111\u1ECBnh"
|
4247
3905
|
}, form.getInputProps("decisionCode"))
|
4248
3906
|
),
|
4249
|
-
/* @__PURE__ */
|
3907
|
+
/* @__PURE__ */ jsx69(
|
4250
3908
|
MyDateInput,
|
4251
3909
|
__spreadValues({
|
4252
3910
|
withAsterisk: true,
|
4253
3911
|
label: "Ng\xE0y ban h\xE0nh"
|
4254
3912
|
}, form.getInputProps("promulgateDate"))
|
4255
3913
|
),
|
4256
|
-
/* @__PURE__ */
|
3914
|
+
/* @__PURE__ */ jsx69(
|
4257
3915
|
MyTextInput,
|
4258
3916
|
__spreadValues({
|
4259
3917
|
withAsterisk: true,
|
4260
3918
|
label: "T\xEAn t\xE0i li\u1EC7u"
|
4261
3919
|
}, form.getInputProps("name"))
|
4262
3920
|
),
|
4263
|
-
/* @__PURE__ */
|
3921
|
+
/* @__PURE__ */ jsx69(
|
4264
3922
|
F_core18256_Select,
|
4265
3923
|
__spreadValues({
|
4266
3924
|
withAsterisk: true,
|
@@ -4268,14 +3926,14 @@ function F_organizationPolicyDocs_Update({
|
|
4268
3926
|
documentTypeId: RegulationsTypeId
|
4269
3927
|
}, form.getInputProps("documentAttributeId"))
|
4270
3928
|
),
|
4271
|
-
/* @__PURE__ */
|
3929
|
+
/* @__PURE__ */ jsx69(
|
4272
3930
|
MyFileInput,
|
4273
3931
|
__spreadValues({
|
4274
3932
|
withAsterisk: true,
|
4275
3933
|
label: "V\u0103n b\u1EA3n"
|
4276
3934
|
}, form.getInputProps("file"))
|
4277
3935
|
),
|
4278
|
-
/* @__PURE__ */
|
3936
|
+
/* @__PURE__ */ jsx69(
|
4279
3937
|
MyNumberInput,
|
4280
3938
|
__spreadValues({
|
4281
3939
|
label: "Th\u1EE9 t\u1EF1 hi\u1EC3n th\u1ECB tr\xEAn danh s\xE1ch"
|
@@ -4287,12 +3945,12 @@ function F_organizationPolicyDocs_Update({
|
|
4287
3945
|
}
|
4288
3946
|
|
4289
3947
|
// src/modules-features/admin/core/organizationPolicyDocs/F_organizationPolicyDocs_Read.tsx
|
4290
|
-
import { jsx as
|
3948
|
+
import { jsx as jsx70, jsxs as jsxs46 } from "react/jsx-runtime";
|
4291
3949
|
function F_organizationPolicyDocs_Read({
|
4292
3950
|
RegulationsTypeId
|
4293
3951
|
}) {
|
4294
3952
|
var _a, _b, _c;
|
4295
|
-
const documentAttributeQuery =
|
3953
|
+
const documentAttributeQuery = useQuery17({
|
4296
3954
|
queryKey: ["F_organizationPolicyDocs_Read", RegulationsTypeId],
|
4297
3955
|
queryFn: async () => {
|
4298
3956
|
var _a2;
|
@@ -4303,10 +3961,10 @@ function F_organizationPolicyDocs_Read({
|
|
4303
3961
|
}
|
4304
3962
|
});
|
4305
3963
|
if (((_a = documentAttributeQuery.data) == null ? void 0 : _a.length) == 0)
|
4306
|
-
return /* @__PURE__ */
|
3964
|
+
return /* @__PURE__ */ jsx70(Blockquote5, { color: "yellow", children: "Ch\u01B0a c\xF3 lo\u1EA1i v\u0103n b\u1EA3n" });
|
4307
3965
|
if (documentAttributeQuery.isError)
|
4308
|
-
return /* @__PURE__ */
|
4309
|
-
return /* @__PURE__ */
|
3966
|
+
return /* @__PURE__ */ jsx70(Alert5, { icon: /* @__PURE__ */ jsx70(IconBug5, {}), color: "red", title: "C\xF3 l\u1ED7i x\u1EA3y ra!", m: "md" });
|
3967
|
+
return /* @__PURE__ */ jsx70(Skeleton5, { h: 500, visible: documentAttributeQuery.isLoading, children: /* @__PURE__ */ jsx70(MyFlexColumn, { children: /* @__PURE__ */ jsx70(
|
4310
3968
|
Accordion5,
|
4311
3969
|
{
|
4312
3970
|
variant: "contained",
|
@@ -4317,7 +3975,7 @@ function F_organizationPolicyDocs_Read({
|
|
4317
3975
|
}
|
4318
3976
|
),
|
4319
3977
|
multiple: true,
|
4320
|
-
children: (_c = documentAttributeQuery.data) == null ? void 0 : _c.map((item, idx) => /* @__PURE__ */
|
3978
|
+
children: (_c = documentAttributeQuery.data) == null ? void 0 : _c.map((item, idx) => /* @__PURE__ */ jsx70(
|
4321
3979
|
SubRead5,
|
4322
3980
|
{
|
4323
3981
|
name: item.name,
|
@@ -4334,7 +3992,7 @@ function SubRead5({
|
|
4334
3992
|
documentType,
|
4335
3993
|
RegulationsTypeId
|
4336
3994
|
}) {
|
4337
|
-
const documentQuery =
|
3995
|
+
const documentQuery = useQuery17({
|
4338
3996
|
queryKey: ["SubRead" + documentType],
|
4339
3997
|
queryFn: async () => {
|
4340
3998
|
const result = await baseAxios_default.get(
|
@@ -4343,7 +4001,7 @@ function SubRead5({
|
|
4343
4001
|
return result.data.data;
|
4344
4002
|
}
|
4345
4003
|
});
|
4346
|
-
const columns =
|
4004
|
+
const columns = useMemo15(
|
4347
4005
|
() => [
|
4348
4006
|
{
|
4349
4007
|
header: "S\u1ED1 quy \u0111\u1ECBnh",
|
@@ -4360,30 +4018,30 @@ function SubRead5({
|
|
4360
4018
|
{
|
4361
4019
|
header: "File",
|
4362
4020
|
accessorFn: (row) => {
|
4363
|
-
return /* @__PURE__ */
|
4021
|
+
return /* @__PURE__ */ jsx70(MyCenterFull, { children: /* @__PURE__ */ jsx70(MyButtonViewPDF, { id: row.id }) });
|
4364
4022
|
}
|
4365
4023
|
}
|
4366
4024
|
],
|
4367
4025
|
[]
|
4368
4026
|
);
|
4369
|
-
return /* @__PURE__ */
|
4370
|
-
/* @__PURE__ */
|
4371
|
-
/* @__PURE__ */
|
4027
|
+
return /* @__PURE__ */ jsxs46(Accordion5.Item, { value: documentType.toString(), children: [
|
4028
|
+
/* @__PURE__ */ jsx70(Accordion5.Control, { children: name }),
|
4029
|
+
/* @__PURE__ */ jsx70(Accordion5.Panel, { children: /* @__PURE__ */ jsx70(
|
4372
4030
|
MyDataTable,
|
4373
4031
|
{
|
4374
4032
|
isLoading: documentQuery.isLoading,
|
4375
4033
|
isError: documentQuery.isError,
|
4376
4034
|
columns,
|
4377
4035
|
data: documentQuery.data || [],
|
4378
|
-
renderRowActions: ({ row }) => /* @__PURE__ */
|
4379
|
-
/* @__PURE__ */
|
4036
|
+
renderRowActions: ({ row }) => /* @__PURE__ */ jsxs46(MyCenterFull, { children: [
|
4037
|
+
/* @__PURE__ */ jsx70(
|
4380
4038
|
F_organizationPolicyDocs_Update,
|
4381
4039
|
{
|
4382
4040
|
RegulationsTypeId,
|
4383
4041
|
values: row.original
|
4384
4042
|
}
|
4385
4043
|
),
|
4386
|
-
/* @__PURE__ */
|
4044
|
+
/* @__PURE__ */ jsx70(
|
4387
4045
|
F_organizationPolicyDocs_Delete,
|
4388
4046
|
{
|
4389
4047
|
id: row.original.id,
|
@@ -4397,12 +4055,12 @@ function SubRead5({
|
|
4397
4055
|
}
|
4398
4056
|
|
4399
4057
|
// src/modules-features/admin/core/organizationPolicyDocs/F_organizationPolicyDocs.tsx
|
4400
|
-
import { jsx as
|
4058
|
+
import { jsx as jsx71, jsxs as jsxs47 } from "react/jsx-runtime";
|
4401
4059
|
function F_organizationPolicyDocs({ RegulationsTypeId }) {
|
4402
|
-
return /* @__PURE__ */
|
4403
|
-
/* @__PURE__ */
|
4404
|
-
/* @__PURE__ */
|
4405
|
-
/* @__PURE__ */
|
4060
|
+
return /* @__PURE__ */ jsxs47(Paper8, { p: "md", children: [
|
4061
|
+
/* @__PURE__ */ jsx71(MyFlexEnd, { children: /* @__PURE__ */ jsx71(F_organizationPolicyDocs_Create, { RegulationsTypeId }) }),
|
4062
|
+
/* @__PURE__ */ jsx71(Space5, {}),
|
4063
|
+
/* @__PURE__ */ jsx71(F_organizationPolicyDocs_Read, { RegulationsTypeId })
|
4406
4064
|
] });
|
4407
4065
|
}
|
4408
4066
|
|
@@ -4411,11 +4069,11 @@ var CONTROLLER2 = "/eva/PageContent";
|
|
4411
4069
|
var service_PageContent = __spreadValues({}, createBaseApi(CONTROLLER2, baseAxios_default));
|
4412
4070
|
|
4413
4071
|
// src/modules-features/admin/core/pageContentConfig/F_pageContentConfig_ReadMenu.tsx
|
4414
|
-
import { Group as
|
4415
|
-
import { useMemo as
|
4072
|
+
import { Group as Group4 } from "@mantine/core";
|
4073
|
+
import { useMemo as useMemo16 } from "react";
|
4416
4074
|
|
4417
4075
|
// src/modules-features/admin/core/pageContentConfig/F_pageContentConfig_Save.tsx
|
4418
|
-
import { jsx as
|
4076
|
+
import { jsx as jsx72 } from "react/jsx-runtime";
|
4419
4077
|
function F_pageContentConfig_Save({ menuValues }) {
|
4420
4078
|
const updatePageConfigMutation = useMyReactMutation({
|
4421
4079
|
axiosFn: () => {
|
@@ -4423,30 +4081,30 @@ function F_pageContentConfig_Save({ menuValues }) {
|
|
4423
4081
|
return service_PageContent.updateList([{ id: 1 }]);
|
4424
4082
|
}
|
4425
4083
|
});
|
4426
|
-
return /* @__PURE__ */
|
4084
|
+
return /* @__PURE__ */ jsx72(MyButton2, { actionType: "save", onClick: () => updatePageConfigMutation.mutate({}) });
|
4427
4085
|
}
|
4428
4086
|
|
4429
4087
|
// src/modules-features/admin/core/pageContentConfig/F_pageContentConfig_Export.tsx
|
4430
|
-
import { jsx as
|
4088
|
+
import { jsx as jsx73 } from "react/jsx-runtime";
|
4431
4089
|
function F_pageContentConfig_Export() {
|
4432
|
-
return /* @__PURE__ */
|
4090
|
+
return /* @__PURE__ */ jsx73(MyButton2, { actionType: "export" });
|
4433
4091
|
}
|
4434
4092
|
|
4435
4093
|
// src/modules-features/admin/core/pageContentConfig/F_pageContentConfig_DeleteDescription.tsx
|
4436
|
-
import { jsx as
|
4094
|
+
import { jsx as jsx74 } from "react/jsx-runtime";
|
4437
4095
|
function F_pageContentConfig_DeleteDescription() {
|
4438
|
-
return /* @__PURE__ */
|
4096
|
+
return /* @__PURE__ */ jsx74(MyButton2, { actionType: "delete" });
|
4439
4097
|
}
|
4440
4098
|
|
4441
4099
|
// src/modules-features/admin/core/pageContentConfig/F_pageContentConfig_ReadMenu.tsx
|
4442
|
-
import { jsx as
|
4100
|
+
import { jsx as jsx75, jsxs as jsxs48 } from "react/jsx-runtime";
|
4443
4101
|
function F_pageContentConfig_ReadMenu() {
|
4444
4102
|
const pageContentQuery = useMyReactQuery({
|
4445
4103
|
queryKey: ["pageContentQuery"],
|
4446
4104
|
axiosFn: () => service_PageContent.getAll()
|
4447
4105
|
});
|
4448
4106
|
const device = useMyDevice();
|
4449
|
-
const columns =
|
4107
|
+
const columns = useMemo16(() => [
|
4450
4108
|
{
|
4451
4109
|
header: "Dashboard",
|
4452
4110
|
accessorKey: "name"
|
@@ -4456,77 +4114,77 @@ function F_pageContentConfig_ReadMenu() {
|
|
4456
4114
|
accessorKey: "description",
|
4457
4115
|
size: device.isPc ? 400 : 0,
|
4458
4116
|
Cell: () => {
|
4459
|
-
return /* @__PURE__ */
|
4117
|
+
return /* @__PURE__ */ jsx75(MyTextInput2, { placeholder: "Nh\u1EADp m\xF4 t\u1EA3 menu" });
|
4460
4118
|
}
|
4461
4119
|
}
|
4462
4120
|
], []);
|
4463
|
-
return /* @__PURE__ */
|
4121
|
+
return /* @__PURE__ */ jsx75(
|
4464
4122
|
MyDataTable,
|
4465
4123
|
{
|
4466
4124
|
isLoading: pageContentQuery.isLoading,
|
4467
4125
|
isError: pageContentQuery.isError,
|
4468
4126
|
data: pageContentQuery.data || [],
|
4469
4127
|
columns,
|
4470
|
-
renderTopToolbarCustomActions: (row) => /* @__PURE__ */
|
4471
|
-
/* @__PURE__ */
|
4472
|
-
/* @__PURE__ */
|
4473
|
-
/* @__PURE__ */
|
4128
|
+
renderTopToolbarCustomActions: (row) => /* @__PURE__ */ jsxs48(Group4, { children: [
|
4129
|
+
/* @__PURE__ */ jsx75(F_pageContentConfig_Save, { menuValues: [] }),
|
4130
|
+
/* @__PURE__ */ jsx75(F_pageContentConfig_Export, {}),
|
4131
|
+
/* @__PURE__ */ jsx75(F_pageContentConfig_DeleteDescription, {})
|
4474
4132
|
] })
|
4475
4133
|
}
|
4476
4134
|
);
|
4477
4135
|
}
|
4478
4136
|
|
4479
4137
|
// src/modules-features/admin/core/pageContentConfig/F_pageContentConfig.tsx
|
4480
|
-
import { jsx as
|
4138
|
+
import { jsx as jsx76 } from "react/jsx-runtime";
|
4481
4139
|
function F_pageContentConfig() {
|
4482
|
-
return /* @__PURE__ */
|
4140
|
+
return /* @__PURE__ */ jsx76(F_pageContentConfig_ReadMenu, {});
|
4483
4141
|
}
|
4484
4142
|
|
4485
4143
|
// src/modules-features/admin/core/roleCatalog/F_roleCatalog_Read.tsx
|
4486
|
-
import { Group as
|
4487
|
-
import { useQuery as
|
4488
|
-
import { useMemo as
|
4144
|
+
import { Group as Group5 } from "@mantine/core";
|
4145
|
+
import { useQuery as useQuery18 } from "@tanstack/react-query";
|
4146
|
+
import { useMemo as useMemo17 } from "react";
|
4489
4147
|
|
4490
4148
|
// src/modules-features/admin/core/roleCatalog/F_roleCatalog_Delete.tsx
|
4491
|
-
import { jsx as
|
4492
|
-
var
|
4149
|
+
import { jsx as jsx77 } from "react/jsx-runtime";
|
4150
|
+
var ENDPOINT4 = "/Role/Delete";
|
4493
4151
|
function F_roleCatalog_Delete({ values }) {
|
4494
|
-
return /* @__PURE__ */
|
4152
|
+
return /* @__PURE__ */ jsx77(
|
4495
4153
|
MyActionIconDelete,
|
4496
4154
|
{
|
4497
4155
|
contextData: values.code,
|
4498
|
-
onSubmit: () => baseAxios_default.post(
|
4156
|
+
onSubmit: () => baseAxios_default.post(ENDPOINT4, { id: values.id })
|
4499
4157
|
}
|
4500
4158
|
);
|
4501
4159
|
}
|
4502
4160
|
|
4503
4161
|
// src/modules-features/admin/core/roleCatalog/F_roleCatalog_Form.tsx
|
4504
|
-
import { useForm as
|
4505
|
-
import { jsx as
|
4162
|
+
import { useForm as useForm24 } from "@mantine/form";
|
4163
|
+
import { jsx as jsx78, jsxs as jsxs49 } from "react/jsx-runtime";
|
4506
4164
|
function F_roleCatalog_Form({ values }) {
|
4507
|
-
const form =
|
4165
|
+
const form = useForm24({
|
4508
4166
|
mode: "uncontrolled",
|
4509
4167
|
initialValues: values
|
4510
4168
|
});
|
4511
|
-
if (values) return /* @__PURE__ */
|
4169
|
+
if (values) return /* @__PURE__ */ jsxs49(MyActionIconUpdate, { form, onSubmit: async () => {
|
4512
4170
|
return await baseAxios_default.post("/Role/Update", form.getValues());
|
4513
4171
|
}, children: [
|
4514
|
-
/* @__PURE__ */
|
4515
|
-
/* @__PURE__ */
|
4172
|
+
/* @__PURE__ */ jsx78(MyTextInput, __spreadValues({ readOnly: true, variant: "filled", label: "M\xE3" }, form.getInputProps("code"))),
|
4173
|
+
/* @__PURE__ */ jsx78(MyTextInput, __spreadValues({ label: "Quy\u1EC1n" }, form.getInputProps("name")))
|
4516
4174
|
] });
|
4517
|
-
return /* @__PURE__ */
|
4175
|
+
return /* @__PURE__ */ jsxs49(MyButtonCreate, { form, onSubmit: async () => {
|
4518
4176
|
return await baseAxios_default.post("/Role/Create", form.getValues());
|
4519
4177
|
}, children: [
|
4520
|
-
/* @__PURE__ */
|
4521
|
-
/* @__PURE__ */
|
4178
|
+
/* @__PURE__ */ jsx78(MyTextInput, __spreadValues({ label: "M\xE3" }, form.getInputProps("code"))),
|
4179
|
+
/* @__PURE__ */ jsx78(MyTextInput, __spreadValues({ label: "Quy\u1EC1n" }, form.getInputProps("name")))
|
4522
4180
|
] });
|
4523
4181
|
}
|
4524
4182
|
|
4525
4183
|
// src/modules-features/admin/core/roleCatalog/F_roleCatalog_Read.tsx
|
4526
|
-
import { jsx as
|
4184
|
+
import { jsx as jsx79, jsxs as jsxs50 } from "react/jsx-runtime";
|
4527
4185
|
function F_roleCatalog_Read() {
|
4528
4186
|
const query = useQ_core47643_GetAdminRole2();
|
4529
|
-
const columns =
|
4187
|
+
const columns = useMemo17(() => [
|
4530
4188
|
{
|
4531
4189
|
header: "M\xE3",
|
4532
4190
|
accessorKey: "code"
|
@@ -4536,48 +4194,83 @@ function F_roleCatalog_Read() {
|
|
4536
4194
|
accessorKey: "name"
|
4537
4195
|
}
|
4538
4196
|
], []);
|
4539
|
-
|
4540
|
-
if (query.isError) return "C\xF3 l\u1ED7i x\u1EA3y ra!";
|
4541
|
-
return /* @__PURE__ */ jsx85(
|
4197
|
+
return /* @__PURE__ */ jsx79(
|
4542
4198
|
MyDataTable,
|
4543
4199
|
{
|
4544
|
-
|
4200
|
+
isLoading: query.isLoading,
|
4201
|
+
isError: query.isError,
|
4202
|
+
data: query.data || [],
|
4545
4203
|
columns,
|
4546
|
-
renderTopToolbarCustomActions: () => /* @__PURE__ */
|
4547
|
-
renderRowActions: ({ row }) => /* @__PURE__ */
|
4548
|
-
/* @__PURE__ */
|
4549
|
-
/* @__PURE__ */
|
4204
|
+
renderTopToolbarCustomActions: () => /* @__PURE__ */ jsx79(Group5, { children: /* @__PURE__ */ jsx79(F_roleCatalog_Form, {}) }),
|
4205
|
+
renderRowActions: ({ row }) => /* @__PURE__ */ jsxs50(MyCenterFull, { children: [
|
4206
|
+
/* @__PURE__ */ jsx79(F_roleCatalog_Form, { values: row.original }),
|
4207
|
+
/* @__PURE__ */ jsx79(F_roleCatalog_Delete, { values: row.original })
|
4550
4208
|
] })
|
4551
4209
|
}
|
4552
4210
|
);
|
4553
4211
|
}
|
4554
4212
|
function useQ_core47643_GetAdminRole2() {
|
4555
|
-
const query =
|
4213
|
+
const query = useQuery18({
|
4556
4214
|
queryKey: ["useQ_core47643_GetAdminRole"],
|
4557
4215
|
queryFn: async () => {
|
4558
4216
|
const res = await baseAxios_default.get("/Role/GetAdminRole");
|
4217
|
+
if (process.env.NEXT_PUBLIC_APP_PROTOTYPE == "1") return mockData2;
|
4559
4218
|
return res.data.data;
|
4560
4219
|
}
|
4561
4220
|
});
|
4562
4221
|
return query;
|
4563
4222
|
}
|
4223
|
+
var mockData2 = [
|
4224
|
+
{
|
4225
|
+
"aqModuleId": 3,
|
4226
|
+
"id": 6,
|
4227
|
+
"code": "GV",
|
4228
|
+
"name": "Gi\u1EA3ng vi\xEAn",
|
4229
|
+
"concurrencyStamp": null,
|
4230
|
+
"isEnabled": true
|
4231
|
+
},
|
4232
|
+
{
|
4233
|
+
"aqModuleId": 3,
|
4234
|
+
"id": 1009,
|
4235
|
+
"code": "10",
|
4236
|
+
"name": "Student",
|
4237
|
+
"concurrencyStamp": "3bbf95fd-4c2a-4d49-a4f8-7b422c64ce0f",
|
4238
|
+
"isEnabled": true
|
4239
|
+
},
|
4240
|
+
{
|
4241
|
+
"aqModuleId": 3,
|
4242
|
+
"id": 1010,
|
4243
|
+
"code": "11",
|
4244
|
+
"name": "Faculty",
|
4245
|
+
"concurrencyStamp": "3bbf95fd-4c2a-4d49-a4f8-7b422c64ce0f",
|
4246
|
+
"isEnabled": true
|
4247
|
+
},
|
4248
|
+
{
|
4249
|
+
"aqModuleId": 3,
|
4250
|
+
"id": 1011,
|
4251
|
+
"code": "12",
|
4252
|
+
"name": "Admin",
|
4253
|
+
"concurrencyStamp": "3bbf95fd-4c2a-4d49-a4f8-7b422c64ce0f",
|
4254
|
+
"isEnabled": true
|
4255
|
+
}
|
4256
|
+
];
|
4564
4257
|
|
4565
4258
|
// src/modules-features/admin/core/roleCatalog/F_roleCatalog.tsx
|
4566
|
-
import { jsx as
|
4259
|
+
import { jsx as jsx80 } from "react/jsx-runtime";
|
4567
4260
|
function F_roleCatalog() {
|
4568
|
-
return /* @__PURE__ */
|
4261
|
+
return /* @__PURE__ */ jsx80(MyPageContent, { title: "Danh m\u1EE5c quy\u1EC1n", canBack: true, children: /* @__PURE__ */ jsx80(F_roleCatalog_Read, {}) });
|
4569
4262
|
}
|
4570
4263
|
|
4571
4264
|
// src/modules-features/admin/core/securityPolicyDocs/F_securityPolicyDocs_Read.tsx
|
4572
|
-
import { useQuery as
|
4573
|
-
import { useMemo as
|
4265
|
+
import { useQuery as useQuery19 } from "@tanstack/react-query";
|
4266
|
+
import { useMemo as useMemo18 } from "react";
|
4574
4267
|
|
4575
4268
|
// src/modules-features/admin/core/securityPolicyDocs/F_securityPolicyDocs_Create.tsx
|
4576
4269
|
import { FileInput as FileInput7 } from "@mantine/core";
|
4577
|
-
import { useForm as
|
4578
|
-
import { jsx as
|
4270
|
+
import { useForm as useForm25 } from "@mantine/form";
|
4271
|
+
import { jsx as jsx81, jsxs as jsxs51 } from "react/jsx-runtime";
|
4579
4272
|
function F_securityPolicyDocs_Create({ SecurityTypeId }) {
|
4580
|
-
const form =
|
4273
|
+
const form = useForm25({
|
4581
4274
|
mode: "uncontrolled",
|
4582
4275
|
validate: {
|
4583
4276
|
decisionCode: (value) => value ? null : "Kh\xF4ng \u0111\u01B0\u1EE3c \u0111\u1EC3 tr\u1ED1ng",
|
@@ -4586,7 +4279,7 @@ function F_securityPolicyDocs_Create({ SecurityTypeId }) {
|
|
4586
4279
|
file: (value) => value ? null : "Kh\xF4ng \u0111\u01B0\u1EE3c \u0111\u1EC3 tr\u1ED1ng"
|
4587
4280
|
}
|
4588
4281
|
});
|
4589
|
-
return /* @__PURE__ */
|
4282
|
+
return /* @__PURE__ */ jsxs51(
|
4590
4283
|
MyButtonCreate,
|
4591
4284
|
{
|
4592
4285
|
objectName: "v\u0103n b\u1EA3n",
|
@@ -4599,28 +4292,28 @@ function F_securityPolicyDocs_Create({ SecurityTypeId }) {
|
|
4599
4292
|
}));
|
4600
4293
|
},
|
4601
4294
|
children: [
|
4602
|
-
/* @__PURE__ */
|
4295
|
+
/* @__PURE__ */ jsx81(
|
4603
4296
|
MyTextInput,
|
4604
4297
|
__spreadValues({
|
4605
4298
|
withAsterisk: true,
|
4606
4299
|
label: "S\u1ED1 quy \u0111\u1ECBnh"
|
4607
4300
|
}, form.getInputProps("decisionCode"))
|
4608
4301
|
),
|
4609
|
-
/* @__PURE__ */
|
4302
|
+
/* @__PURE__ */ jsx81(
|
4610
4303
|
MyDateInput,
|
4611
4304
|
__spreadValues({
|
4612
4305
|
withAsterisk: true,
|
4613
4306
|
label: "Ng\xE0y ban h\xE0nh"
|
4614
4307
|
}, form.getInputProps("promulgateDate"))
|
4615
4308
|
),
|
4616
|
-
/* @__PURE__ */
|
4309
|
+
/* @__PURE__ */ jsx81(
|
4617
4310
|
MyTextInput,
|
4618
4311
|
__spreadValues({
|
4619
4312
|
withAsterisk: true,
|
4620
4313
|
label: "T\xEAn t\xE0i li\u1EC7u"
|
4621
4314
|
}, form.getInputProps("name"))
|
4622
4315
|
),
|
4623
|
-
/* @__PURE__ */
|
4316
|
+
/* @__PURE__ */ jsx81(
|
4624
4317
|
FileInput7,
|
4625
4318
|
__spreadValues({
|
4626
4319
|
withAsterisk: true,
|
@@ -4634,12 +4327,12 @@ function F_securityPolicyDocs_Create({ SecurityTypeId }) {
|
|
4634
4327
|
}
|
4635
4328
|
|
4636
4329
|
// src/modules-features/admin/core/securityPolicyDocs/F_securityPolicyDocs_Delete.tsx
|
4637
|
-
import { jsx as
|
4330
|
+
import { jsx as jsx82 } from "react/jsx-runtime";
|
4638
4331
|
function F_securityPolicyDocs_Delete({
|
4639
4332
|
id,
|
4640
4333
|
contextData
|
4641
4334
|
}) {
|
4642
|
-
return /* @__PURE__ */
|
4335
|
+
return /* @__PURE__ */ jsx82(
|
4643
4336
|
MyActionIconDelete,
|
4644
4337
|
{
|
4645
4338
|
contextData,
|
@@ -4650,11 +4343,11 @@ function F_securityPolicyDocs_Delete({
|
|
4650
4343
|
|
4651
4344
|
// src/modules-features/admin/core/securityPolicyDocs/F_securityPolicyDocs_Update.tsx
|
4652
4345
|
import { FileInput as FileInput8, TextInput as TextInput2 } from "@mantine/core";
|
4653
|
-
import { useForm as
|
4654
|
-
import { jsx as
|
4346
|
+
import { useForm as useForm26 } from "@mantine/form";
|
4347
|
+
import { jsx as jsx83, jsxs as jsxs52 } from "react/jsx-runtime";
|
4655
4348
|
function F_securityPolicyDocs_Update({ values }) {
|
4656
4349
|
var _a;
|
4657
|
-
const form =
|
4350
|
+
const form = useForm26({
|
4658
4351
|
mode: "uncontrolled",
|
4659
4352
|
initialValues: __spreadProps(__spreadValues({}, values), {
|
4660
4353
|
file: new File(
|
@@ -4670,7 +4363,7 @@ function F_securityPolicyDocs_Update({ values }) {
|
|
4670
4363
|
file: (value) => value ? null : "Kh\xF4ng \u0111\u01B0\u1EE3c \u0111\u1EC3 tr\u1ED1ng"
|
4671
4364
|
}
|
4672
4365
|
});
|
4673
|
-
return /* @__PURE__ */
|
4366
|
+
return /* @__PURE__ */ jsxs52(
|
4674
4367
|
MyActionIconUpdate,
|
4675
4368
|
{
|
4676
4369
|
form,
|
@@ -4680,28 +4373,28 @@ function F_securityPolicyDocs_Update({ values }) {
|
|
4680
4373
|
}));
|
4681
4374
|
},
|
4682
4375
|
children: [
|
4683
|
-
/* @__PURE__ */
|
4376
|
+
/* @__PURE__ */ jsx83(
|
4684
4377
|
TextInput2,
|
4685
4378
|
__spreadValues({
|
4686
4379
|
withAsterisk: true,
|
4687
4380
|
label: "S\u1ED1 quy \u0111\u1ECBnh"
|
4688
4381
|
}, form.getInputProps("decisionCode"))
|
4689
4382
|
),
|
4690
|
-
/* @__PURE__ */
|
4383
|
+
/* @__PURE__ */ jsx83(
|
4691
4384
|
MyDateInput,
|
4692
4385
|
__spreadValues({
|
4693
4386
|
withAsterisk: true,
|
4694
4387
|
label: "Ng\xE0y ban h\xE0nh"
|
4695
4388
|
}, form.getInputProps("promulgateDate"))
|
4696
4389
|
),
|
4697
|
-
/* @__PURE__ */
|
4390
|
+
/* @__PURE__ */ jsx83(
|
4698
4391
|
TextInput2,
|
4699
4392
|
__spreadValues({
|
4700
4393
|
withAsterisk: true,
|
4701
4394
|
label: "T\xEAn t\xE0i li\u1EC7u"
|
4702
4395
|
}, form.getInputProps("name"))
|
4703
4396
|
),
|
4704
|
-
/* @__PURE__ */
|
4397
|
+
/* @__PURE__ */ jsx83(
|
4705
4398
|
FileInput8,
|
4706
4399
|
__spreadValues({
|
4707
4400
|
withAsterisk: true,
|
@@ -4714,9 +4407,9 @@ function F_securityPolicyDocs_Update({ values }) {
|
|
4714
4407
|
}
|
4715
4408
|
|
4716
4409
|
// src/modules-features/admin/core/securityPolicyDocs/F_securityPolicyDocs_Read.tsx
|
4717
|
-
import { jsx as
|
4410
|
+
import { jsx as jsx84, jsxs as jsxs53 } from "react/jsx-runtime";
|
4718
4411
|
function F_securityPolicyDocs_Read({ SecurityTypeId }) {
|
4719
|
-
const query =
|
4412
|
+
const query = useQuery19({
|
4720
4413
|
queryKey: ["F_securityPolicyDocs_Read"],
|
4721
4414
|
queryFn: async () => {
|
4722
4415
|
var _a;
|
@@ -4726,7 +4419,7 @@ function F_securityPolicyDocs_Read({ SecurityTypeId }) {
|
|
4726
4419
|
return ((_a = result.data) == null ? void 0 : _a.data) || [];
|
4727
4420
|
}
|
4728
4421
|
});
|
4729
|
-
const columns =
|
4422
|
+
const columns = useMemo18(
|
4730
4423
|
() => [
|
4731
4424
|
{
|
4732
4425
|
header: "S\u1ED1 quy \u0111\u1ECBnh",
|
@@ -4743,25 +4436,25 @@ function F_securityPolicyDocs_Read({ SecurityTypeId }) {
|
|
4743
4436
|
{
|
4744
4437
|
header: "File",
|
4745
4438
|
accessorFn: (row) => {
|
4746
|
-
return /* @__PURE__ */
|
4439
|
+
return /* @__PURE__ */ jsx84(MyCenterFull, { children: /* @__PURE__ */ jsx84(MyButtonViewPDF, { id: row.id }) });
|
4747
4440
|
}
|
4748
4441
|
}
|
4749
4442
|
],
|
4750
4443
|
[]
|
4751
4444
|
);
|
4752
|
-
return /* @__PURE__ */
|
4445
|
+
return /* @__PURE__ */ jsx84(
|
4753
4446
|
MyDataTable,
|
4754
4447
|
{
|
4755
4448
|
isLoading: query.isLoading,
|
4756
4449
|
isError: query.isError,
|
4757
4450
|
columns,
|
4758
4451
|
data: query.data || [],
|
4759
|
-
renderTopToolbarCustomActions: () => /* @__PURE__ */
|
4452
|
+
renderTopToolbarCustomActions: () => /* @__PURE__ */ jsx84(F_securityPolicyDocs_Create, { SecurityTypeId }),
|
4760
4453
|
renderRowActions: ({ row }) => {
|
4761
4454
|
var _a;
|
4762
|
-
return /* @__PURE__ */
|
4763
|
-
/* @__PURE__ */
|
4764
|
-
/* @__PURE__ */
|
4455
|
+
return /* @__PURE__ */ jsxs53(MyCenterFull, { children: [
|
4456
|
+
/* @__PURE__ */ jsx84(F_securityPolicyDocs_Update, { values: row.original }),
|
4457
|
+
/* @__PURE__ */ jsx84(
|
4765
4458
|
F_securityPolicyDocs_Delete,
|
4766
4459
|
{
|
4767
4460
|
id: row.original.id,
|
@@ -4775,23 +4468,23 @@ function F_securityPolicyDocs_Read({ SecurityTypeId }) {
|
|
4775
4468
|
}
|
4776
4469
|
|
4777
4470
|
// src/modules-features/admin/core/securityPolicyDocs/F_securityPolicyDocs.tsx
|
4778
|
-
import { jsx as
|
4471
|
+
import { jsx as jsx85 } from "react/jsx-runtime";
|
4779
4472
|
function F_securityPolicyDocs({ SecurityTypeId }) {
|
4780
|
-
return /* @__PURE__ */
|
4473
|
+
return /* @__PURE__ */ jsx85(F_securityPolicyDocs_Read, { SecurityTypeId });
|
4781
4474
|
}
|
4782
4475
|
|
4783
4476
|
// src/modules-features/admin/core/systemUpdateDocs/F_systemUpdateDocs.tsx
|
4784
|
-
import { useQuery as
|
4785
|
-
import { useMemo as
|
4477
|
+
import { useQuery as useQuery20 } from "@tanstack/react-query";
|
4478
|
+
import { useMemo as useMemo19 } from "react";
|
4786
4479
|
|
4787
4480
|
// src/modules-features/admin/core/systemUpdateDocs/F_systemUpdateDocs_Create.tsx
|
4788
4481
|
import { FileInput as FileInput9, Textarea as Textarea3 } from "@mantine/core";
|
4789
|
-
import { useForm as
|
4790
|
-
import { jsx as
|
4482
|
+
import { useForm as useForm27 } from "@mantine/form";
|
4483
|
+
import { jsx as jsx86, jsxs as jsxs54 } from "react/jsx-runtime";
|
4791
4484
|
function F_systemUpdateDocs_Create({
|
4792
4485
|
RefinementTypeId
|
4793
4486
|
}) {
|
4794
|
-
const form =
|
4487
|
+
const form = useForm27({
|
4795
4488
|
mode: "uncontrolled",
|
4796
4489
|
validate: {
|
4797
4490
|
meetingDate: (value) => value ? null : "Kh\xF4ng \u0111\u01B0\u1EE3c \u0111\u1EC3 tr\u1ED1ng",
|
@@ -4802,7 +4495,7 @@ function F_systemUpdateDocs_Create({
|
|
4802
4495
|
endDate: (value, values) => value && values.startDate && new Date(value) > new Date(values.startDate) ? null : "Ng\xE0y k\u1EBFt th\xFAc ph\u1EA3i l\u1EDBn h\u01A1n ng\xE0y b\u1EAFt \u0111\u1EA7u"
|
4803
4496
|
}
|
4804
4497
|
});
|
4805
|
-
return /* @__PURE__ */
|
4498
|
+
return /* @__PURE__ */ jsxs54(
|
4806
4499
|
MyButtonCreate,
|
4807
4500
|
{
|
4808
4501
|
objectName: "v\u0103n b\u1EA3n",
|
@@ -4815,43 +4508,43 @@ function F_systemUpdateDocs_Create({
|
|
4815
4508
|
}));
|
4816
4509
|
},
|
4817
4510
|
children: [
|
4818
|
-
/* @__PURE__ */
|
4511
|
+
/* @__PURE__ */ jsx86(
|
4819
4512
|
MyDateInput,
|
4820
4513
|
__spreadValues({
|
4821
4514
|
withAsterisk: true,
|
4822
4515
|
label: "Ng\xE0y h\u1ECDp"
|
4823
4516
|
}, form.getInputProps("meetingDate"))
|
4824
4517
|
),
|
4825
|
-
/* @__PURE__ */
|
4518
|
+
/* @__PURE__ */ jsx86(
|
4826
4519
|
MyTextInput,
|
4827
4520
|
__spreadValues({
|
4828
4521
|
withAsterisk: true,
|
4829
4522
|
label: "\u0110\u01A1n v\u1ECB y\xEAu c\u1EA7u"
|
4830
4523
|
}, form.getInputProps("departmentName"))
|
4831
4524
|
),
|
4832
|
-
/* @__PURE__ */
|
4525
|
+
/* @__PURE__ */ jsx86(
|
4833
4526
|
MyTextInput,
|
4834
4527
|
__spreadValues({
|
4835
4528
|
withAsterisk: true,
|
4836
4529
|
label: "N\u1ED9i dung c\u1EA3i ti\u1EBFn"
|
4837
4530
|
}, form.getInputProps("description"))
|
4838
4531
|
),
|
4839
|
-
/* @__PURE__ */
|
4840
|
-
/* @__PURE__ */
|
4532
|
+
/* @__PURE__ */ jsx86(MyTextInput, __spreadValues({ label: "K\u1EBFt lu\u1EADn" }, form.getInputProps("conclusion"))),
|
4533
|
+
/* @__PURE__ */ jsx86(
|
4841
4534
|
MyDateInput,
|
4842
4535
|
__spreadValues({
|
4843
4536
|
withAsterisk: true,
|
4844
4537
|
label: "Ng\xE0y b\u1EAFt \u0111\u1EA7u"
|
4845
4538
|
}, form.getInputProps("startDate"))
|
4846
4539
|
),
|
4847
|
-
/* @__PURE__ */
|
4540
|
+
/* @__PURE__ */ jsx86(
|
4848
4541
|
MyDateInput,
|
4849
4542
|
__spreadValues({
|
4850
4543
|
withAsterisk: true,
|
4851
4544
|
label: "Ng\xE0y k\u1EBFt th\xFAc"
|
4852
4545
|
}, form.getInputProps("endDate"))
|
4853
4546
|
),
|
4854
|
-
/* @__PURE__ */
|
4547
|
+
/* @__PURE__ */ jsx86(
|
4855
4548
|
FileInput9,
|
4856
4549
|
__spreadValues({
|
4857
4550
|
placeholder: "T\u1EA3i l\xEAn t\xE0i li\u1EC7u",
|
@@ -4859,19 +4552,19 @@ function F_systemUpdateDocs_Create({
|
|
4859
4552
|
label: "T\xE0i li\u1EC7u"
|
4860
4553
|
}, form.getInputProps("file"))
|
4861
4554
|
),
|
4862
|
-
/* @__PURE__ */
|
4555
|
+
/* @__PURE__ */ jsx86(Textarea3, __spreadValues({ label: "Ghi ch\xFA" }, form.getInputProps("note")))
|
4863
4556
|
]
|
4864
4557
|
}
|
4865
4558
|
);
|
4866
4559
|
}
|
4867
4560
|
|
4868
4561
|
// src/modules-features/admin/core/systemUpdateDocs/F_systemUpdateDocs_Delete.tsx
|
4869
|
-
import { jsx as
|
4562
|
+
import { jsx as jsx87 } from "react/jsx-runtime";
|
4870
4563
|
function F_systemUpdateDocs_Delete({
|
4871
4564
|
id,
|
4872
4565
|
contextData
|
4873
4566
|
}) {
|
4874
|
-
return /* @__PURE__ */
|
4567
|
+
return /* @__PURE__ */ jsx87(
|
4875
4568
|
MyActionIconDelete,
|
4876
4569
|
{
|
4877
4570
|
contextData,
|
@@ -4882,11 +4575,11 @@ function F_systemUpdateDocs_Delete({
|
|
4882
4575
|
|
4883
4576
|
// src/modules-features/admin/core/systemUpdateDocs/F_systemUpdateDocs_Update.tsx
|
4884
4577
|
import { FileInput as FileInput10, Textarea as Textarea4 } from "@mantine/core";
|
4885
|
-
import { useForm as
|
4886
|
-
import { jsx as
|
4578
|
+
import { useForm as useForm28 } from "@mantine/form";
|
4579
|
+
import { jsx as jsx88, jsxs as jsxs55 } from "react/jsx-runtime";
|
4887
4580
|
function F_systemUpdateDocs_Update({ values }) {
|
4888
4581
|
var _a;
|
4889
|
-
const form =
|
4582
|
+
const form = useForm28({
|
4890
4583
|
mode: "uncontrolled",
|
4891
4584
|
initialValues: __spreadProps(__spreadValues({}, values), {
|
4892
4585
|
file: new File(
|
@@ -4906,7 +4599,7 @@ function F_systemUpdateDocs_Update({ values }) {
|
|
4906
4599
|
endDate: (value, values2) => value && values2.startDate && new Date(value) > new Date(values2.startDate) ? null : "Ng\xE0y k\u1EBFt th\xFAc ph\u1EA3i l\u1EDBn h\u01A1n ng\xE0y b\u1EAFt \u0111\u1EA7u"
|
4907
4600
|
}
|
4908
4601
|
});
|
4909
|
-
return /* @__PURE__ */
|
4602
|
+
return /* @__PURE__ */ jsxs55(
|
4910
4603
|
MyActionIconUpdate,
|
4911
4604
|
{
|
4912
4605
|
form,
|
@@ -4916,43 +4609,43 @@ function F_systemUpdateDocs_Update({ values }) {
|
|
4916
4609
|
}));
|
4917
4610
|
},
|
4918
4611
|
children: [
|
4919
|
-
/* @__PURE__ */
|
4612
|
+
/* @__PURE__ */ jsx88(
|
4920
4613
|
MyDateInput,
|
4921
4614
|
__spreadValues({
|
4922
4615
|
withAsterisk: true,
|
4923
4616
|
label: "Ng\xE0y h\u1ECDp"
|
4924
4617
|
}, form.getInputProps("meetingDate"))
|
4925
4618
|
),
|
4926
|
-
/* @__PURE__ */
|
4619
|
+
/* @__PURE__ */ jsx88(
|
4927
4620
|
MyTextInput,
|
4928
4621
|
__spreadValues({
|
4929
4622
|
withAsterisk: true,
|
4930
4623
|
label: "\u0110\u01A1n v\u1ECB y\xEAu c\u1EA7u"
|
4931
4624
|
}, form.getInputProps("departmentName"))
|
4932
4625
|
),
|
4933
|
-
/* @__PURE__ */
|
4626
|
+
/* @__PURE__ */ jsx88(
|
4934
4627
|
MyTextInput,
|
4935
4628
|
__spreadValues({
|
4936
4629
|
withAsterisk: true,
|
4937
4630
|
label: "N\u1ED9i dung c\u1EA3i ti\u1EBFn"
|
4938
4631
|
}, form.getInputProps("description"))
|
4939
4632
|
),
|
4940
|
-
/* @__PURE__ */
|
4941
|
-
/* @__PURE__ */
|
4633
|
+
/* @__PURE__ */ jsx88(MyTextInput, __spreadValues({ label: "K\u1EBFt lu\u1EADn" }, form.getInputProps("conclusion"))),
|
4634
|
+
/* @__PURE__ */ jsx88(
|
4942
4635
|
MyDateInput,
|
4943
4636
|
__spreadValues({
|
4944
4637
|
withAsterisk: true,
|
4945
4638
|
label: "Ng\xE0y b\u1EAFt \u0111\u1EA7u"
|
4946
4639
|
}, form.getInputProps("startDate"))
|
4947
4640
|
),
|
4948
|
-
/* @__PURE__ */
|
4641
|
+
/* @__PURE__ */ jsx88(
|
4949
4642
|
MyDateInput,
|
4950
4643
|
__spreadValues({
|
4951
4644
|
withAsterisk: true,
|
4952
4645
|
label: "Ng\xE0y k\u1EBFt th\xFAc"
|
4953
4646
|
}, form.getInputProps("endDate"))
|
4954
4647
|
),
|
4955
|
-
/* @__PURE__ */
|
4648
|
+
/* @__PURE__ */ jsx88(
|
4956
4649
|
FileInput10,
|
4957
4650
|
__spreadValues({
|
4958
4651
|
placeholder: "T\u1EA3i l\xEAn t\xE0i li\u1EC7u",
|
@@ -4960,16 +4653,16 @@ function F_systemUpdateDocs_Update({ values }) {
|
|
4960
4653
|
label: "T\xE0i li\u1EC7u"
|
4961
4654
|
}, form.getInputProps("file"))
|
4962
4655
|
),
|
4963
|
-
/* @__PURE__ */
|
4656
|
+
/* @__PURE__ */ jsx88(Textarea4, __spreadValues({ label: "Ghi ch\xFA" }, form.getInputProps("note")))
|
4964
4657
|
]
|
4965
4658
|
}
|
4966
4659
|
);
|
4967
4660
|
}
|
4968
4661
|
|
4969
4662
|
// src/modules-features/admin/core/systemUpdateDocs/F_systemUpdateDocs.tsx
|
4970
|
-
import { jsx as
|
4663
|
+
import { jsx as jsx89, jsxs as jsxs56 } from "react/jsx-runtime";
|
4971
4664
|
function F_systemUpdateDocs({ RefinementTypeId }) {
|
4972
|
-
const query =
|
4665
|
+
const query = useQuery20({
|
4973
4666
|
queryKey: ["F_systemUpdateDocs_Read"],
|
4974
4667
|
queryFn: async () => {
|
4975
4668
|
var _a;
|
@@ -4979,7 +4672,7 @@ function F_systemUpdateDocs({ RefinementTypeId }) {
|
|
4979
4672
|
return ((_a = result.data) == null ? void 0 : _a.data) || [];
|
4980
4673
|
}
|
4981
4674
|
});
|
4982
|
-
const columns =
|
4675
|
+
const columns = useMemo19(
|
4983
4676
|
() => [
|
4984
4677
|
{
|
4985
4678
|
header: "\u0110\u01A1n v\u1ECB y\xEAu c\u1EA7u",
|
@@ -5000,24 +4693,24 @@ function F_systemUpdateDocs({ RefinementTypeId }) {
|
|
5000
4693
|
{
|
5001
4694
|
header: "File",
|
5002
4695
|
accessorFn: (row) => {
|
5003
|
-
return /* @__PURE__ */
|
4696
|
+
return /* @__PURE__ */ jsx89(MyCenterFull, { children: /* @__PURE__ */ jsx89(MyButtonViewPDF, { id: row.id }) });
|
5004
4697
|
}
|
5005
4698
|
}
|
5006
4699
|
],
|
5007
4700
|
[]
|
5008
4701
|
);
|
5009
|
-
return /* @__PURE__ */
|
4702
|
+
return /* @__PURE__ */ jsx89(
|
5010
4703
|
MyDataTable,
|
5011
4704
|
{
|
5012
4705
|
isLoading: query.isLoading,
|
5013
4706
|
isError: query.isError,
|
5014
4707
|
columns,
|
5015
4708
|
data: query.data || [],
|
5016
|
-
renderTopToolbarCustomActions: () => /* @__PURE__ */
|
4709
|
+
renderTopToolbarCustomActions: () => /* @__PURE__ */ jsx89(F_systemUpdateDocs_Create, { RefinementTypeId }),
|
5017
4710
|
renderRowActions: ({ row }) => {
|
5018
|
-
return /* @__PURE__ */
|
5019
|
-
/* @__PURE__ */
|
5020
|
-
/* @__PURE__ */
|
4711
|
+
return /* @__PURE__ */ jsxs56(MyCenterFull, { children: [
|
4712
|
+
/* @__PURE__ */ jsx89(F_systemUpdateDocs_Update, { values: row.original }),
|
4713
|
+
/* @__PURE__ */ jsx89(
|
5021
4714
|
F_systemUpdateDocs_Delete,
|
5022
4715
|
{
|
5023
4716
|
id: row.original.id,
|
@@ -5031,15 +4724,15 @@ function F_systemUpdateDocs({ RefinementTypeId }) {
|
|
5031
4724
|
}
|
5032
4725
|
|
5033
4726
|
// src/modules-features/admin/core/userGuideDocs/F_userGuideDocs_Read.tsx
|
5034
|
-
import { useQuery as
|
5035
|
-
import { useMemo as
|
4727
|
+
import { useQuery as useQuery21 } from "@tanstack/react-query";
|
4728
|
+
import { useMemo as useMemo20 } from "react";
|
5036
4729
|
|
5037
4730
|
// src/modules-features/admin/core/userGuideDocs/F_userGuideDocs_Create.tsx
|
5038
4731
|
import { FileInput as FileInput11 } from "@mantine/core";
|
5039
|
-
import { useForm as
|
5040
|
-
import { jsx as
|
4732
|
+
import { useForm as useForm29 } from "@mantine/form";
|
4733
|
+
import { jsx as jsx90, jsxs as jsxs57 } from "react/jsx-runtime";
|
5041
4734
|
function F_userGuideDocs_Create({ GuidelineTypeId }) {
|
5042
|
-
const form =
|
4735
|
+
const form = useForm29({
|
5043
4736
|
mode: "uncontrolled",
|
5044
4737
|
validate: {
|
5045
4738
|
code: (value) => value ? null : "Kh\xF4ng \u0111\u01B0\u1EE3c \u0111\u1EC3 tr\u1ED1ng",
|
@@ -5047,7 +4740,7 @@ function F_userGuideDocs_Create({ GuidelineTypeId }) {
|
|
5047
4740
|
file: (value) => value ? null : "Kh\xF4ng \u0111\u01B0\u1EE3c \u0111\u1EC3 tr\u1ED1ng"
|
5048
4741
|
}
|
5049
4742
|
});
|
5050
|
-
return /* @__PURE__ */
|
4743
|
+
return /* @__PURE__ */ jsxs57(
|
5051
4744
|
MyButtonCreate,
|
5052
4745
|
{
|
5053
4746
|
objectName: "v\u0103n b\u1EA3n",
|
@@ -5060,21 +4753,21 @@ function F_userGuideDocs_Create({ GuidelineTypeId }) {
|
|
5060
4753
|
}));
|
5061
4754
|
},
|
5062
4755
|
children: [
|
5063
|
-
/* @__PURE__ */
|
4756
|
+
/* @__PURE__ */ jsx90(
|
5064
4757
|
MyTextInput,
|
5065
4758
|
__spreadValues({
|
5066
4759
|
withAsterisk: true,
|
5067
4760
|
label: "M\xE3 t\xE0i li\u1EC7u"
|
5068
4761
|
}, form.getInputProps("code"))
|
5069
4762
|
),
|
5070
|
-
/* @__PURE__ */
|
4763
|
+
/* @__PURE__ */ jsx90(
|
5071
4764
|
MyTextInput,
|
5072
4765
|
__spreadValues({
|
5073
4766
|
withAsterisk: true,
|
5074
4767
|
label: "T\xEAn t\xE0i li\u1EC7u"
|
5075
4768
|
}, form.getInputProps("name"))
|
5076
4769
|
),
|
5077
|
-
/* @__PURE__ */
|
4770
|
+
/* @__PURE__ */ jsx90(
|
5078
4771
|
FileInput11,
|
5079
4772
|
__spreadValues({
|
5080
4773
|
withAsterisk: true,
|
@@ -5088,12 +4781,12 @@ function F_userGuideDocs_Create({ GuidelineTypeId }) {
|
|
5088
4781
|
}
|
5089
4782
|
|
5090
4783
|
// src/modules-features/admin/core/userGuideDocs/F_userGuideDocs_Delete.tsx
|
5091
|
-
import { jsx as
|
4784
|
+
import { jsx as jsx91 } from "react/jsx-runtime";
|
5092
4785
|
function F_userGuideDocs_Delete({
|
5093
4786
|
id,
|
5094
4787
|
contextData
|
5095
4788
|
}) {
|
5096
|
-
return /* @__PURE__ */
|
4789
|
+
return /* @__PURE__ */ jsx91(
|
5097
4790
|
MyActionIconDelete,
|
5098
4791
|
{
|
5099
4792
|
contextData,
|
@@ -5104,11 +4797,11 @@ function F_userGuideDocs_Delete({
|
|
5104
4797
|
|
5105
4798
|
// src/modules-features/admin/core/userGuideDocs/F_userGuideDocs_Update.tsx
|
5106
4799
|
import { FileInput as FileInput12 } from "@mantine/core";
|
5107
|
-
import { useForm as
|
5108
|
-
import { jsx as
|
4800
|
+
import { useForm as useForm30 } from "@mantine/form";
|
4801
|
+
import { jsx as jsx92, jsxs as jsxs58 } from "react/jsx-runtime";
|
5109
4802
|
function F_userGuideDocs_Update({ values }) {
|
5110
4803
|
var _a;
|
5111
|
-
const form =
|
4804
|
+
const form = useForm30({
|
5112
4805
|
mode: "uncontrolled",
|
5113
4806
|
initialValues: __spreadProps(__spreadValues({}, values), {
|
5114
4807
|
file: new File(
|
@@ -5122,7 +4815,7 @@ function F_userGuideDocs_Update({ values }) {
|
|
5122
4815
|
file: (value) => value ? null : "Kh\xF4ng \u0111\u01B0\u1EE3c \u0111\u1EC3 tr\u1ED1ng"
|
5123
4816
|
}
|
5124
4817
|
});
|
5125
|
-
return /* @__PURE__ */
|
4818
|
+
return /* @__PURE__ */ jsxs58(
|
5126
4819
|
MyActionIconUpdate,
|
5127
4820
|
{
|
5128
4821
|
form,
|
@@ -5132,21 +4825,21 @@ function F_userGuideDocs_Update({ values }) {
|
|
5132
4825
|
}));
|
5133
4826
|
},
|
5134
4827
|
children: [
|
5135
|
-
/* @__PURE__ */
|
4828
|
+
/* @__PURE__ */ jsx92(
|
5136
4829
|
MyTextInput,
|
5137
4830
|
__spreadValues({
|
5138
4831
|
withAsterisk: true,
|
5139
4832
|
label: "M\xE3 t\xE0i li\u1EC7u"
|
5140
4833
|
}, form.getInputProps("code"))
|
5141
4834
|
),
|
5142
|
-
/* @__PURE__ */
|
4835
|
+
/* @__PURE__ */ jsx92(
|
5143
4836
|
MyTextInput,
|
5144
4837
|
__spreadValues({
|
5145
4838
|
withAsterisk: true,
|
5146
4839
|
label: "T\xEAn t\xE0i li\u1EC7u"
|
5147
4840
|
}, form.getInputProps("name"))
|
5148
4841
|
),
|
5149
|
-
/* @__PURE__ */
|
4842
|
+
/* @__PURE__ */ jsx92(
|
5150
4843
|
FileInput12,
|
5151
4844
|
__spreadValues({
|
5152
4845
|
withAsterisk: true,
|
@@ -5160,9 +4853,9 @@ function F_userGuideDocs_Update({ values }) {
|
|
5160
4853
|
}
|
5161
4854
|
|
5162
4855
|
// src/modules-features/admin/core/userGuideDocs/F_userGuideDocs_Read.tsx
|
5163
|
-
import { jsx as
|
4856
|
+
import { jsx as jsx93, jsxs as jsxs59 } from "react/jsx-runtime";
|
5164
4857
|
function F_userGuideDocs_Read({ GuidelineTypeId }) {
|
5165
|
-
const query =
|
4858
|
+
const query = useQuery21({
|
5166
4859
|
queryKey: ["F_userGuideDocs_Read"],
|
5167
4860
|
queryFn: async () => {
|
5168
4861
|
var _a;
|
@@ -5172,7 +4865,7 @@ function F_userGuideDocs_Read({ GuidelineTypeId }) {
|
|
5172
4865
|
return ((_a = result.data) == null ? void 0 : _a.data) || [];
|
5173
4866
|
}
|
5174
4867
|
});
|
5175
|
-
const columns =
|
4868
|
+
const columns = useMemo20(
|
5176
4869
|
() => [
|
5177
4870
|
{
|
5178
4871
|
header: "M\xE3 t\xE0i li\u1EC7u",
|
@@ -5185,24 +4878,24 @@ function F_userGuideDocs_Read({ GuidelineTypeId }) {
|
|
5185
4878
|
{
|
5186
4879
|
header: "File",
|
5187
4880
|
accessorFn: (row) => {
|
5188
|
-
return /* @__PURE__ */
|
4881
|
+
return /* @__PURE__ */ jsx93(MyCenterFull, { children: /* @__PURE__ */ jsx93(MyButtonViewPDF, { id: row.id }) });
|
5189
4882
|
}
|
5190
4883
|
}
|
5191
4884
|
],
|
5192
4885
|
[]
|
5193
4886
|
);
|
5194
|
-
return /* @__PURE__ */
|
4887
|
+
return /* @__PURE__ */ jsx93(
|
5195
4888
|
MyDataTable,
|
5196
4889
|
{
|
5197
4890
|
isLoading: query.isLoading,
|
5198
4891
|
isError: query.isError,
|
5199
4892
|
columns,
|
5200
4893
|
data: query.data || [],
|
5201
|
-
renderTopToolbarCustomActions: () => /* @__PURE__ */
|
4894
|
+
renderTopToolbarCustomActions: () => /* @__PURE__ */ jsx93(F_userGuideDocs_Create, { GuidelineTypeId }),
|
5202
4895
|
renderRowActions: ({ row }) => {
|
5203
|
-
return /* @__PURE__ */
|
5204
|
-
/* @__PURE__ */
|
5205
|
-
/* @__PURE__ */
|
4896
|
+
return /* @__PURE__ */ jsxs59(MyCenterFull, { children: [
|
4897
|
+
/* @__PURE__ */ jsx93(F_userGuideDocs_Update, { values: row.original }),
|
4898
|
+
/* @__PURE__ */ jsx93(
|
5206
4899
|
F_userGuideDocs_Delete,
|
5207
4900
|
{
|
5208
4901
|
id: row.original.id,
|
@@ -5216,21 +4909,21 @@ function F_userGuideDocs_Read({ GuidelineTypeId }) {
|
|
5216
4909
|
}
|
5217
4910
|
|
5218
4911
|
// src/modules-features/admin/core/userGuideDocs/F_userGuideDocs.tsx
|
5219
|
-
import { jsx as
|
4912
|
+
import { jsx as jsx94 } from "react/jsx-runtime";
|
5220
4913
|
function F_userGuideDocs({ GuidelineTypeId }) {
|
5221
|
-
return /* @__PURE__ */
|
4914
|
+
return /* @__PURE__ */ jsx94(F_userGuideDocs_Read, { GuidelineTypeId });
|
5222
4915
|
}
|
5223
4916
|
|
5224
4917
|
// src/modules-features/admin/core/workflowProcessDocs/F_workflowProcessDocs.tsx
|
5225
4918
|
import { Paper as Paper9, Space as Space6 } from "@mantine/core";
|
5226
4919
|
|
5227
4920
|
// src/modules-features/admin/core/workflowProcessDocs/F_workflowProcessDocs_Create.tsx
|
5228
|
-
import { useForm as
|
5229
|
-
import { jsx as
|
4921
|
+
import { useForm as useForm31 } from "@mantine/form";
|
4922
|
+
import { jsx as jsx95, jsxs as jsxs60 } from "react/jsx-runtime";
|
5230
4923
|
function F_workflowProcessDocs_Create({
|
5231
4924
|
WorkflowTypeId
|
5232
4925
|
}) {
|
5233
|
-
const form =
|
4926
|
+
const form = useForm31({
|
5234
4927
|
mode: "uncontrolled",
|
5235
4928
|
validate: {
|
5236
4929
|
decisionCode: (value) => value ? null : "S\u1ED1 quy \u0111\u1ECBnh kh\xF4ng \u0111\u01B0\u1EE3c \u0111\u1EC3 tr\u1ED1ng",
|
@@ -5240,7 +4933,7 @@ function F_workflowProcessDocs_Create({
|
|
5240
4933
|
file: (value) => value ? null : "T\u1EC7p \u0111\xEDnh k\xE8m kh\xF4ng \u0111\u01B0\u1EE3c \u0111\u1EC3 tr\u1ED1ng"
|
5241
4934
|
}
|
5242
4935
|
});
|
5243
|
-
return /* @__PURE__ */
|
4936
|
+
return /* @__PURE__ */ jsxs60(
|
5244
4937
|
MyButtonCreate,
|
5245
4938
|
{
|
5246
4939
|
objectName: "V\u0103n b\u1EA3n quy \u0111\u1ECBnh t\u1ED5 ch\u1EE9c",
|
@@ -5252,28 +4945,28 @@ function F_workflowProcessDocs_Create({
|
|
5252
4945
|
}));
|
5253
4946
|
},
|
5254
4947
|
children: [
|
5255
|
-
/* @__PURE__ */
|
4948
|
+
/* @__PURE__ */ jsx95(
|
5256
4949
|
MyTextInput,
|
5257
4950
|
__spreadValues({
|
5258
4951
|
withAsterisk: true,
|
5259
4952
|
label: "S\u1ED1 quy \u0111\u1ECBnh"
|
5260
4953
|
}, form.getInputProps("decisionCode"))
|
5261
4954
|
),
|
5262
|
-
/* @__PURE__ */
|
4955
|
+
/* @__PURE__ */ jsx95(
|
5263
4956
|
MyDateInput,
|
5264
4957
|
__spreadValues({
|
5265
4958
|
withAsterisk: true,
|
5266
4959
|
label: "Ng\xE0y ban h\xE0nh"
|
5267
4960
|
}, form.getInputProps("promulgateDate"))
|
5268
4961
|
),
|
5269
|
-
/* @__PURE__ */
|
4962
|
+
/* @__PURE__ */ jsx95(
|
5270
4963
|
MyTextInput,
|
5271
4964
|
__spreadValues({
|
5272
4965
|
withAsterisk: true,
|
5273
4966
|
label: "T\xEAn t\xE0i li\u1EC7u"
|
5274
4967
|
}, form.getInputProps("name"))
|
5275
4968
|
),
|
5276
|
-
/* @__PURE__ */
|
4969
|
+
/* @__PURE__ */ jsx95(
|
5277
4970
|
F_core18256_Select,
|
5278
4971
|
__spreadValues({
|
5279
4972
|
withAsterisk: true,
|
@@ -5281,14 +4974,14 @@ function F_workflowProcessDocs_Create({
|
|
5281
4974
|
documentTypeId: WorkflowTypeId
|
5282
4975
|
}, form.getInputProps("documentAttributeId"))
|
5283
4976
|
),
|
5284
|
-
/* @__PURE__ */
|
4977
|
+
/* @__PURE__ */ jsx95(
|
5285
4978
|
MyFileInput,
|
5286
4979
|
__spreadValues({
|
5287
4980
|
withAsterisk: true,
|
5288
4981
|
label: "V\u0103n b\u1EA3n"
|
5289
4982
|
}, form.getInputProps("file"))
|
5290
4983
|
),
|
5291
|
-
/* @__PURE__ */
|
4984
|
+
/* @__PURE__ */ jsx95(
|
5292
4985
|
MyNumberInput,
|
5293
4986
|
__spreadValues({
|
5294
4987
|
label: "Th\u1EE9 t\u1EF1 hi\u1EC3n th\u1ECB tr\xEAn danh s\xE1ch"
|
@@ -5301,17 +4994,17 @@ function F_workflowProcessDocs_Create({
|
|
5301
4994
|
|
5302
4995
|
// src/modules-features/admin/core/workflowProcessDocs/F_workflowProcessDocs_Read.tsx
|
5303
4996
|
import { Accordion as Accordion6, Alert as Alert6, Blockquote as Blockquote6, Skeleton as Skeleton6 } from "@mantine/core";
|
5304
|
-
import { useQuery as
|
4997
|
+
import { useQuery as useQuery22 } from "@tanstack/react-query";
|
5305
4998
|
import { IconBug as IconBug6 } from "@tabler/icons-react";
|
5306
|
-
import { useMemo as
|
4999
|
+
import { useMemo as useMemo21 } from "react";
|
5307
5000
|
|
5308
5001
|
// src/modules-features/admin/core/workflowProcessDocs/F_workflowProcessDocs_Delete.tsx
|
5309
|
-
import { jsx as
|
5002
|
+
import { jsx as jsx96 } from "react/jsx-runtime";
|
5310
5003
|
function F_workflowProcessDocs_Delete({
|
5311
5004
|
id,
|
5312
5005
|
contextData
|
5313
5006
|
}) {
|
5314
|
-
return /* @__PURE__ */
|
5007
|
+
return /* @__PURE__ */ jsx96(
|
5315
5008
|
MyActionIconDelete,
|
5316
5009
|
{
|
5317
5010
|
contextData,
|
@@ -5321,14 +5014,14 @@ function F_workflowProcessDocs_Delete({
|
|
5321
5014
|
}
|
5322
5015
|
|
5323
5016
|
// src/modules-features/admin/core/workflowProcessDocs/F_workflowProcessDocs_Update.tsx
|
5324
|
-
import { useForm as
|
5325
|
-
import { jsx as
|
5017
|
+
import { useForm as useForm32 } from "@mantine/form";
|
5018
|
+
import { jsx as jsx97, jsxs as jsxs61 } from "react/jsx-runtime";
|
5326
5019
|
function F_workflowProcessDocs_Update({
|
5327
5020
|
values,
|
5328
5021
|
WorkflowTypeId
|
5329
5022
|
}) {
|
5330
5023
|
var _a;
|
5331
|
-
const form =
|
5024
|
+
const form = useForm32({
|
5332
5025
|
initialValues: __spreadProps(__spreadValues({}, values), {
|
5333
5026
|
file: new File(
|
5334
5027
|
[],
|
@@ -5344,7 +5037,7 @@ function F_workflowProcessDocs_Update({
|
|
5344
5037
|
file: (value) => value ? null : "T\u1EC7p \u0111\xEDnh k\xE8m kh\xF4ng \u0111\u01B0\u1EE3c \u0111\u1EC3 tr\u1ED1ng"
|
5345
5038
|
}
|
5346
5039
|
});
|
5347
|
-
return /* @__PURE__ */
|
5040
|
+
return /* @__PURE__ */ jsxs61(
|
5348
5041
|
MyActionIconUpdate,
|
5349
5042
|
{
|
5350
5043
|
form,
|
@@ -5354,28 +5047,28 @@ function F_workflowProcessDocs_Update({
|
|
5354
5047
|
}));
|
5355
5048
|
},
|
5356
5049
|
children: [
|
5357
|
-
/* @__PURE__ */
|
5050
|
+
/* @__PURE__ */ jsx97(
|
5358
5051
|
MyTextInput,
|
5359
5052
|
__spreadValues({
|
5360
5053
|
withAsterisk: true,
|
5361
5054
|
label: "S\u1ED1 quy \u0111\u1ECBnh"
|
5362
5055
|
}, form.getInputProps("decisionCode"))
|
5363
5056
|
),
|
5364
|
-
/* @__PURE__ */
|
5057
|
+
/* @__PURE__ */ jsx97(
|
5365
5058
|
MyDateInput,
|
5366
5059
|
__spreadValues({
|
5367
5060
|
withAsterisk: true,
|
5368
5061
|
label: "Ng\xE0y ban h\xE0nh"
|
5369
5062
|
}, form.getInputProps("promulgateDate"))
|
5370
5063
|
),
|
5371
|
-
/* @__PURE__ */
|
5064
|
+
/* @__PURE__ */ jsx97(
|
5372
5065
|
MyTextInput,
|
5373
5066
|
__spreadValues({
|
5374
5067
|
withAsterisk: true,
|
5375
5068
|
label: "T\xEAn t\xE0i li\u1EC7u"
|
5376
5069
|
}, form.getInputProps("name"))
|
5377
5070
|
),
|
5378
|
-
/* @__PURE__ */
|
5071
|
+
/* @__PURE__ */ jsx97(
|
5379
5072
|
F_core18256_Select,
|
5380
5073
|
__spreadValues({
|
5381
5074
|
withAsterisk: true,
|
@@ -5383,14 +5076,14 @@ function F_workflowProcessDocs_Update({
|
|
5383
5076
|
documentTypeId: WorkflowTypeId
|
5384
5077
|
}, form.getInputProps("documentAttributeId"))
|
5385
5078
|
),
|
5386
|
-
/* @__PURE__ */
|
5079
|
+
/* @__PURE__ */ jsx97(
|
5387
5080
|
MyFileInput,
|
5388
5081
|
__spreadValues({
|
5389
5082
|
withAsterisk: true,
|
5390
5083
|
label: "V\u0103n b\u1EA3n"
|
5391
5084
|
}, form.getInputProps("file"))
|
5392
5085
|
),
|
5393
|
-
/* @__PURE__ */
|
5086
|
+
/* @__PURE__ */ jsx97(
|
5394
5087
|
MyNumberInput,
|
5395
5088
|
__spreadValues({
|
5396
5089
|
label: "Th\u1EE9 t\u1EF1 hi\u1EC3n th\u1ECB tr\xEAn danh s\xE1ch"
|
@@ -5402,12 +5095,12 @@ function F_workflowProcessDocs_Update({
|
|
5402
5095
|
}
|
5403
5096
|
|
5404
5097
|
// src/modules-features/admin/core/workflowProcessDocs/F_workflowProcessDocs_Read.tsx
|
5405
|
-
import { jsx as
|
5098
|
+
import { jsx as jsx98, jsxs as jsxs62 } from "react/jsx-runtime";
|
5406
5099
|
function F_workflowProcessDocs_Read({
|
5407
5100
|
WorkflowTypeId
|
5408
5101
|
}) {
|
5409
5102
|
var _a, _b, _c;
|
5410
|
-
const documentAttributeQuery =
|
5103
|
+
const documentAttributeQuery = useQuery22({
|
5411
5104
|
queryKey: ["F_workflowProcessDocs_Read", WorkflowTypeId],
|
5412
5105
|
queryFn: async () => {
|
5413
5106
|
var _a2;
|
@@ -5418,10 +5111,10 @@ function F_workflowProcessDocs_Read({
|
|
5418
5111
|
}
|
5419
5112
|
});
|
5420
5113
|
if (((_a = documentAttributeQuery.data) == null ? void 0 : _a.length) == 0)
|
5421
|
-
return /* @__PURE__ */
|
5114
|
+
return /* @__PURE__ */ jsx98(Blockquote6, { color: "yellow", children: "Ch\u01B0a c\xF3 lo\u1EA1i v\u0103n b\u1EA3n" });
|
5422
5115
|
if (documentAttributeQuery.isError)
|
5423
|
-
return /* @__PURE__ */
|
5424
|
-
return /* @__PURE__ */
|
5116
|
+
return /* @__PURE__ */ jsx98(Alert6, { icon: /* @__PURE__ */ jsx98(IconBug6, {}), color: "red", title: "C\xF3 l\u1ED7i x\u1EA3y ra!", m: "md" });
|
5117
|
+
return /* @__PURE__ */ jsx98(Skeleton6, { h: 500, visible: documentAttributeQuery.isLoading, children: /* @__PURE__ */ jsx98(MyFlexColumn, { children: /* @__PURE__ */ jsx98(
|
5425
5118
|
Accordion6,
|
5426
5119
|
{
|
5427
5120
|
variant: "contained",
|
@@ -5432,7 +5125,7 @@ function F_workflowProcessDocs_Read({
|
|
5432
5125
|
}
|
5433
5126
|
),
|
5434
5127
|
multiple: true,
|
5435
|
-
children: (_c = documentAttributeQuery.data) == null ? void 0 : _c.map((item, idx) => /* @__PURE__ */
|
5128
|
+
children: (_c = documentAttributeQuery.data) == null ? void 0 : _c.map((item, idx) => /* @__PURE__ */ jsx98(
|
5436
5129
|
SubRead6,
|
5437
5130
|
{
|
5438
5131
|
name: item.name,
|
@@ -5449,7 +5142,7 @@ function SubRead6({
|
|
5449
5142
|
documentType,
|
5450
5143
|
WorkflowTypeId
|
5451
5144
|
}) {
|
5452
|
-
const documentQuery =
|
5145
|
+
const documentQuery = useQuery22({
|
5453
5146
|
queryKey: ["SubRead" + documentType],
|
5454
5147
|
queryFn: async () => {
|
5455
5148
|
const result = await baseAxios_default.get(
|
@@ -5458,7 +5151,7 @@ function SubRead6({
|
|
5458
5151
|
return result.data.data;
|
5459
5152
|
}
|
5460
5153
|
});
|
5461
|
-
const columns =
|
5154
|
+
const columns = useMemo21(
|
5462
5155
|
() => [
|
5463
5156
|
{
|
5464
5157
|
header: "S\u1ED1 quy \u0111\u1ECBnh",
|
@@ -5475,30 +5168,30 @@ function SubRead6({
|
|
5475
5168
|
{
|
5476
5169
|
header: "File",
|
5477
5170
|
accessorFn: (row) => {
|
5478
|
-
return /* @__PURE__ */
|
5171
|
+
return /* @__PURE__ */ jsx98(MyCenterFull, { children: /* @__PURE__ */ jsx98(MyButtonViewPDF, { id: row.id }) });
|
5479
5172
|
}
|
5480
5173
|
}
|
5481
5174
|
],
|
5482
5175
|
[]
|
5483
5176
|
);
|
5484
|
-
return /* @__PURE__ */
|
5485
|
-
/* @__PURE__ */
|
5486
|
-
/* @__PURE__ */
|
5177
|
+
return /* @__PURE__ */ jsxs62(Accordion6.Item, { value: documentType.toString(), children: [
|
5178
|
+
/* @__PURE__ */ jsx98(Accordion6.Control, { children: name }),
|
5179
|
+
/* @__PURE__ */ jsx98(Accordion6.Panel, { children: /* @__PURE__ */ jsx98(
|
5487
5180
|
MyDataTable,
|
5488
5181
|
{
|
5489
5182
|
isLoading: documentQuery.isLoading,
|
5490
5183
|
isError: documentQuery.isError,
|
5491
5184
|
columns,
|
5492
5185
|
data: documentQuery.data || [],
|
5493
|
-
renderRowActions: ({ row }) => /* @__PURE__ */
|
5494
|
-
/* @__PURE__ */
|
5186
|
+
renderRowActions: ({ row }) => /* @__PURE__ */ jsxs62(MyCenterFull, { children: [
|
5187
|
+
/* @__PURE__ */ jsx98(
|
5495
5188
|
F_workflowProcessDocs_Update,
|
5496
5189
|
{
|
5497
5190
|
WorkflowTypeId,
|
5498
5191
|
values: row.original
|
5499
5192
|
}
|
5500
5193
|
),
|
5501
|
-
/* @__PURE__ */
|
5194
|
+
/* @__PURE__ */ jsx98(
|
5502
5195
|
F_workflowProcessDocs_Delete,
|
5503
5196
|
{
|
5504
5197
|
id: row.original.id,
|
@@ -5512,61 +5205,61 @@ function SubRead6({
|
|
5512
5205
|
}
|
5513
5206
|
|
5514
5207
|
// src/modules-features/admin/core/workflowProcessDocs/F_workflowProcessDocs.tsx
|
5515
|
-
import { jsx as
|
5208
|
+
import { jsx as jsx99, jsxs as jsxs63 } from "react/jsx-runtime";
|
5516
5209
|
function F_workflowProcessDocs({
|
5517
5210
|
WorkflowTypeId
|
5518
5211
|
}) {
|
5519
|
-
return /* @__PURE__ */
|
5520
|
-
/* @__PURE__ */
|
5521
|
-
/* @__PURE__ */
|
5522
|
-
/* @__PURE__ */
|
5212
|
+
return /* @__PURE__ */ jsxs63(Paper9, { p: "md", children: [
|
5213
|
+
/* @__PURE__ */ jsx99(MyFlexEnd, { children: /* @__PURE__ */ jsx99(F_workflowProcessDocs_Create, { WorkflowTypeId }) }),
|
5214
|
+
/* @__PURE__ */ jsx99(Space6, {}),
|
5215
|
+
/* @__PURE__ */ jsx99(F_workflowProcessDocs_Read, { WorkflowTypeId })
|
5523
5216
|
] });
|
5524
5217
|
}
|
5525
5218
|
|
5526
5219
|
// src/modules-features/authenticate/F_authenticate_SplashPage.tsx
|
5527
|
-
import { useRouter
|
5528
|
-
import { useEffect as
|
5529
|
-
import { jsx as
|
5220
|
+
import { useRouter } from "next/navigation";
|
5221
|
+
import { useEffect as useEffect11 } from "react";
|
5222
|
+
import { jsx as jsx100 } from "react/jsx-runtime";
|
5530
5223
|
function F_authenticate_SplashPage() {
|
5531
|
-
const router =
|
5224
|
+
const router = useRouter();
|
5532
5225
|
const S_Authenticate = useS_authenticate();
|
5533
|
-
|
5226
|
+
useEffect11(() => {
|
5534
5227
|
if (S_Authenticate.state.token == "") {
|
5535
5228
|
router.push("/authenticate/login");
|
5536
5229
|
return;
|
5537
5230
|
}
|
5538
5231
|
router.push("/admin/core71678");
|
5539
5232
|
}, [S_Authenticate.state.token]);
|
5540
|
-
return /* @__PURE__ */
|
5233
|
+
return /* @__PURE__ */ jsx100(MyBoxesBackground, { title: "H\u1EC7 th\u1ED1ng th\xF4ng tin qu\u1EA3n l\xED \u0111\xE0o t\u1EA1o ng\u1EAFn h\u1EA1n" });
|
5541
5234
|
}
|
5542
5235
|
|
5543
5236
|
// src/modules-features/authenticate/F_authenticate_Login/F_authenticate_Login.tsx
|
5544
5237
|
import {
|
5545
5238
|
Anchor,
|
5546
5239
|
BackgroundImage,
|
5547
|
-
Button as
|
5240
|
+
Button as Button3,
|
5548
5241
|
Center as Center2,
|
5549
5242
|
Checkbox as Checkbox3,
|
5550
5243
|
Flex as Flex3,
|
5551
|
-
Group as
|
5244
|
+
Group as Group6,
|
5552
5245
|
Paper as Paper10,
|
5553
5246
|
PasswordInput as PasswordInput2,
|
5554
5247
|
Text as Text3,
|
5555
5248
|
TextInput as TextInput3,
|
5556
5249
|
Title
|
5557
5250
|
} from "@mantine/core";
|
5558
|
-
import { useForm as
|
5559
|
-
import { useMutation as
|
5251
|
+
import { useForm as useForm33 } from "@mantine/form";
|
5252
|
+
import { useMutation as useMutation5 } from "@tanstack/react-query";
|
5560
5253
|
import axios from "axios";
|
5561
5254
|
import Link from "next/link";
|
5562
|
-
import { useRouter as
|
5563
|
-
import { useEffect as
|
5255
|
+
import { useRouter as useRouter2 } from "next/navigation";
|
5256
|
+
import { useEffect as useEffect12, useState as useState10 } from "react";
|
5564
5257
|
|
5565
5258
|
// src/modules-features/authenticate/F_authenticate_Login/css.module.css
|
5566
5259
|
var css_default = {};
|
5567
5260
|
|
5568
5261
|
// src/modules-features/authenticate/F_authenticate_Login/F_authenticate_Login.tsx
|
5569
|
-
import { jsx as
|
5262
|
+
import { jsx as jsx101, jsxs as jsxs64 } from "react/jsx-runtime";
|
5570
5263
|
function F_authenticate_Login({
|
5571
5264
|
header,
|
5572
5265
|
redirectUrlAfterLogin = "/admin/dashboard",
|
@@ -5577,11 +5270,11 @@ function F_authenticate_Login({
|
|
5577
5270
|
showSaveLogin = true,
|
5578
5271
|
showForgotPassword = true
|
5579
5272
|
}) {
|
5580
|
-
const router =
|
5273
|
+
const router = useRouter2();
|
5581
5274
|
const authenticate_store = useS_authenticate();
|
5582
|
-
const loadingState =
|
5275
|
+
const loadingState = useState10(false);
|
5583
5276
|
const mutation = useM_Account_Sigin();
|
5584
|
-
const form =
|
5277
|
+
const form = useForm33({
|
5585
5278
|
initialValues: {
|
5586
5279
|
username: "",
|
5587
5280
|
password: ""
|
@@ -5591,7 +5284,7 @@ function F_authenticate_Login({
|
|
5591
5284
|
password: (value) => value ? null : "Kh\xF4ng \u0111\u01B0\u1EE3c \u0111\u1EC3 tr\u1ED1ng"
|
5592
5285
|
}
|
5593
5286
|
});
|
5594
|
-
|
5287
|
+
useEffect12(() => {
|
5595
5288
|
var _a;
|
5596
5289
|
form.setValues({
|
5597
5290
|
username: ((_a = authenticate_store.state) == null ? void 0 : _a.username) || "",
|
@@ -5633,21 +5326,21 @@ function F_authenticate_Login({
|
|
5633
5326
|
}
|
5634
5327
|
});
|
5635
5328
|
}
|
5636
|
-
return /* @__PURE__ */
|
5329
|
+
return /* @__PURE__ */ jsx101(
|
5637
5330
|
BackgroundImage,
|
5638
5331
|
{
|
5639
5332
|
src: backgroundImage,
|
5640
5333
|
h: "100vh",
|
5641
|
-
children: /* @__PURE__ */
|
5642
|
-
header ? header : /* @__PURE__ */
|
5643
|
-
/* @__PURE__ */
|
5644
|
-
/* @__PURE__ */
|
5334
|
+
children: /* @__PURE__ */ jsx101(Center2, { h: "100vh", children: /* @__PURE__ */ jsxs64(Paper10, { withBorder: true, w: 400, m: "md", shadow: "md", p: 30, mt: 30, radius: "md", children: [
|
5335
|
+
header ? header : /* @__PURE__ */ jsxs64(Flex3, { direction: "column", mb: "md", children: [
|
5336
|
+
/* @__PURE__ */ jsx101(Title, { ta: "center", className: css_default.title, children: "\u0110\u0103ng nh\u1EADp!" }),
|
5337
|
+
/* @__PURE__ */ jsxs64(Text3, { c: "dimmed", size: "sm", ta: "center", mt: 5, children: [
|
5645
5338
|
"B\u1EA1n g\u1EB7p v\u1EA5n \u0111\u1EC1 k\u1EF9 thu\u1EADt?\xA0",
|
5646
|
-
/* @__PURE__ */
|
5339
|
+
/* @__PURE__ */ jsx101(Anchor, { size: "sm", component: "button", children: "V\xE0o link n\xE0y" })
|
5647
5340
|
] })
|
5648
5341
|
] }),
|
5649
|
-
/* @__PURE__ */
|
5650
|
-
/* @__PURE__ */
|
5342
|
+
/* @__PURE__ */ jsx101("form", { onSubmit: form.onSubmit(async (values) => handleSubmit(values.username, values.password)), children: /* @__PURE__ */ jsxs64(MyFlexColumn, { children: [
|
5343
|
+
/* @__PURE__ */ jsx101(
|
5651
5344
|
TextInput3,
|
5652
5345
|
__spreadProps(__spreadValues({}, form.getInputProps("username")), {
|
5653
5346
|
label: "T\xE0i kho\u1EA3n",
|
@@ -5655,7 +5348,7 @@ function F_authenticate_Login({
|
|
5655
5348
|
withAsterisk: true
|
5656
5349
|
})
|
5657
5350
|
),
|
5658
|
-
/* @__PURE__ */
|
5351
|
+
/* @__PURE__ */ jsx101(
|
5659
5352
|
PasswordInput2,
|
5660
5353
|
__spreadProps(__spreadValues({}, form.getInputProps("password")), {
|
5661
5354
|
label: "M\u1EADt kh\u1EA9u",
|
@@ -5663,8 +5356,8 @@ function F_authenticate_Login({
|
|
5663
5356
|
withAsterisk: true
|
5664
5357
|
})
|
5665
5358
|
),
|
5666
|
-
/* @__PURE__ */
|
5667
|
-
showSaveLogin && /* @__PURE__ */
|
5359
|
+
/* @__PURE__ */ jsxs64(Group6, { justify: "space-between", children: [
|
5360
|
+
showSaveLogin && /* @__PURE__ */ jsx101(
|
5668
5361
|
Checkbox3,
|
5669
5362
|
{
|
5670
5363
|
checked: authenticate_store.state.saveLogin,
|
@@ -5672,10 +5365,10 @@ function F_authenticate_Login({
|
|
5672
5365
|
label: "L\u01B0u \u0111\u0103ng nh\u1EADp"
|
5673
5366
|
}
|
5674
5367
|
),
|
5675
|
-
showForgotPassword && /* @__PURE__ */
|
5368
|
+
showForgotPassword && /* @__PURE__ */ jsx101(Anchor, { component: Link, href: "quen-mat-khau", size: "sm", children: "Qu\xEAn m\u1EADt kh\u1EA9u?" })
|
5676
5369
|
] }),
|
5677
|
-
showLoginButton && /* @__PURE__ */
|
5678
|
-
|
5370
|
+
showLoginButton && /* @__PURE__ */ jsx101(
|
5371
|
+
Button3,
|
5679
5372
|
{
|
5680
5373
|
loading: loadingState[0],
|
5681
5374
|
type: "submit",
|
@@ -5690,7 +5383,7 @@ function F_authenticate_Login({
|
|
5690
5383
|
);
|
5691
5384
|
}
|
5692
5385
|
function useM_Account_Sigin() {
|
5693
|
-
const mutation =
|
5386
|
+
const mutation = useMutation5({
|
5694
5387
|
mutationFn: async (values) => {
|
5695
5388
|
const endpoint = await utils_config_getBaseUrl() + "/Account/SignIn";
|
5696
5389
|
const result = await axios.post(endpoint, values);
|
@@ -5752,12 +5445,6 @@ export {
|
|
5752
5445
|
F_core64229_Delete,
|
5753
5446
|
F_core64229_Form,
|
5754
5447
|
F_core64229_Read,
|
5755
|
-
F_core71678,
|
5756
|
-
F_core71678_ChangePermission,
|
5757
|
-
F_core71678_Create,
|
5758
|
-
F_core71678_Delete,
|
5759
|
-
F_core71678_Read,
|
5760
|
-
F_core71678_Update,
|
5761
5448
|
F_core76318,
|
5762
5449
|
F_core76318_Create,
|
5763
5450
|
F_core76318_Delete,
|