@utogether/udp-core 1.0.1-beta.9 → 1.0.2
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/build/plugins.ts +37 -39
- package/dist/{403-BOzKHdlm.js → 403-B1rIjAAu.js} +6 -6
- package/dist/{404-uwgt4Nll.js → 404-mBqc2y4t.js} +4 -4
- package/dist/{500-4HBf6V9m.js → 500-BoI45Zdh.js} +2 -2
- package/dist/{AuthorityInfo-DvbIh1vT.js → AuthorityInfo-B08NBIIn.js} +1 -1
- package/dist/{AuthorityInfo.vue_vue_type_style_index_0_lang-BlCPvwXU.js → AuthorityInfo.vue_vue_type_style_index_0_lang-BLP1SaiH.js} +3 -3
- package/dist/{Company-D7Q9BFmr.js → Company-JGGyWEWH.js} +3 -3
- package/dist/{CompanyPanel-C0-PJlrt.js → CompanyPanel-BQ_cCmDx.js} +7 -7
- package/dist/{Department-h2hlXACv.js → Department-z2iO6hwM.js} +10 -10
- package/dist/{DepartmentPanel-B6hDEQpG.js → DepartmentPanel-BtQe7zwU.js} +108 -78
- package/dist/{DesignPanel-cS58-1v9.js → DesignPanel-7mhtVWas.js} +1 -1
- package/dist/{DesignPanel.vue_vue_type_style_index_0_lang-LdvLC8VU.js → DesignPanel.vue_vue_type_style_index_0_lang-4EsHemj_.js} +6 -6
- package/dist/{DictView-T3TmpBa8.js → DictView-CjchV2Yk.js} +15 -16
- package/dist/InvOrganization-Pn1O_XP0.js +74 -0
- package/dist/{Org-CnCBDGKF.js → Org-BqytV_vi.js} +1 -1
- package/dist/{Preview-BaktKXB1.js → Preview-CLpUUMay.js} +2 -2
- package/dist/{ReportDefine-5Rb0PO9A.js → ReportDefine-Cz1KtEUF.js} +1 -1
- package/dist/{ReportDesign-DYdkVREA.js → ReportDesign-BaORYud4.js} +13 -13
- package/dist/{ReportQuery-BwhzIXMt.js → ReportQuery-CPCPXiXz.js} +1 -1
- package/dist/{ReportQueryFrom-PHtWwlOe.js → ReportQueryFrom-C_AcrfkJ.js} +1 -1
- package/dist/{ReportQueryFrom.vue_vue_type_style_index_0_lang-BE5yZNPM.js → ReportQueryFrom.vue_vue_type_style_index_0_lang-Bm67ejay.js} +1 -1
- package/dist/{ReportTemplate-DaadVXIi.js → ReportTemplate-CFiNMz79.js} +11 -11
- package/dist/{Role-Dtg3nAmG.js → Role-B-XDoJd5.js} +3 -3
- package/dist/{RoleAssign-DEGtLssH.js → RoleAssign-BolW8YVs.js} +8 -8
- package/dist/{RolePanel-DpUzfE_o.js → RolePanel-2kfs5tw9.js} +1 -1
- package/dist/{RolePanel-CT7BTPmy.js → RolePanel-HilSuYns.js} +1 -1
- package/dist/{RolePanel.vue_vue_type_script_setup_true_lang-Xyo0YEI0.js → RolePanel.vue_vue_type_script_setup_true_lang-CE4gApUY.js} +7 -7
- package/dist/{RolePanel.vue_vue_type_script_setup_true_lang-Dg2A6DJu.js → RolePanel.vue_vue_type_script_setup_true_lang-DPzgfAyV.js} +13 -13
- package/dist/{ScrollPanel.vue_vue_type_style_index_0_lang-CyutzDZS.js → ScrollPanel.vue_vue_type_style_index_0_lang-CCTH4RkH.js} +4 -4
- package/dist/{Staff-_NlAGkrh.js → Staff-BTk3whFC.js} +3 -3
- package/dist/{StaffInfo-DVgUvVgd.js → StaffInfo-d3AuSzlA.js} +1 -1
- package/dist/{StaffInfo.vue_vue_type_script_setup_true_lang-C8hmlFgX.js → StaffInfo.vue_vue_type_script_setup_true_lang-eOL4VlfE.js} +5 -5
- package/dist/{StaffPanel-DKNZE3IE.js → StaffPanel-DV-D4jjz.js} +1 -1
- package/dist/StaffPanel.vue_vue_type_script_setup_true_lang-4sFq3CEo.js +135 -0
- package/dist/{SysUser-kQUf7XKz.js → SysUser-BnjYytws.js} +2 -2
- package/dist/{SysUserPanel-C191uX3U.js → SysUserPanel-CBoyD-Qi.js} +1 -1
- package/dist/SysUserPanel.vue_vue_type_script_setup_true_lang-PrTlTZR-.js +341 -0
- package/dist/{SystemMenu-DwuSvHnj.js → SystemMenu-kYB_ZaUt.js} +36 -36
- package/dist/{UserInfo-DIsInFld.js → UserInfo-4dx97VBL.js} +1 -1
- package/dist/{UserInfo.vue_vue_type_style_index_0_lang-CnvGdbej.js → UserInfo.vue_vue_type_style_index_0_lang-BpbC_ZDm.js} +10 -10
- package/dist/{childView-3Bs2UBEw.js → childView-CHPNfTEb.js} +1 -1
- package/dist/{childView-BawyULD7.js → childView-CKA_JgVZ.js} +1 -1
- package/dist/{childView.vue_vue_type_style_index_0_lang-YpWF-p2F.js → childView.vue_vue_type_style_index_0_lang-Bym2fQRd.js} +7 -7
- package/dist/childView.vue_vue_type_style_index_0_lang-W7bCtXeu.js +177 -0
- package/dist/{code-rule-DVaYcn8S.js → code-rule-CbxuZg0-.js} +40 -38
- package/dist/core.es.js +18 -12
- package/dist/{cron-task-xuzP-BpE.js → cron-task-nTOpqQYf.js} +7 -7
- package/dist/flow-task-B07st2aD.js +10 -0
- package/dist/{frameView-Cudt06qS.js → frameView-Z1tPUyCh.js} +1 -1
- package/dist/index-C3q8HoJM.js +4650 -0
- package/dist/{layoutView-BlFTV2jX.js → layoutView--MGA9zUB.js} +1766 -1760
- package/dist/{log-in-e7D5Ss1P.js → log-in-CSYJDA6m.js} +36 -29
- package/dist/log-out-DiwGCg7p.js +130 -0
- package/dist/login-C6Y0ajDp.js +251 -0
- package/dist/{login-log-kqKzKTto.js → login-log-C0V-_l3F.js} +5 -3
- package/dist/{lov-view-B2HaxyMs.js → lov-view-Cmv7wZZ9.js} +6 -6
- package/dist/{menuInfo-BxCTJ1VW.js → menuInfo-UeutJpOa.js} +1 -1
- package/dist/{menuInfo.vue_vue_type_style_index_0_lang-CLOPNeUW.js → menuInfo.vue_vue_type_style_index_0_lang-CWX4Mu67.js} +118 -98
- package/dist/{pda-app-DPsAFNiw.js → pda-app-B6w99SJo.js} +10 -10
- package/dist/{resource-Dibb7t8u.js → resource-BybJvUv0.js} +4 -4
- package/dist/{su-welcome-DejR0KkM.js → su-welcome-C1bmxHoY.js} +119 -121
- package/dist/sys-config-BnmIDnCj.js +370 -0
- package/dist/udp-core.css +1 -9
- package/dist/utogether-MlnyYtNS.js +4 -0
- package/index.ts +49 -40
- package/package.json +18 -18
- package/src/App.vue +65 -65
- package/src/api/http.ts +1 -4
- package/src/api/index.ts +4 -2
- package/src/api/user.ts +2 -2
- package/src/components/SuCharts/src/UserInfo.vue +78 -78
- package/src/components/SuScrollTree/ScrollPanel.vue +1 -6
- package/src/components/udp/content/index.vue +88 -0
- package/src/components/udp/{form.vue → form/form.vue} +13 -16
- package/src/components/udp/{grid.vue → grid/index.vue} +56 -27
- package/src/components/udp/index.ts +4 -9
- package/src/components/udp/ut-stamp-badge/index.vue +271 -0
- package/src/components/udp/utils.ts +66 -105
- package/src/layout/components/lay-navbar/index.vue +8 -6
- package/src/layout/components/lay-panel/index.vue +150 -150
- package/src/layout/components/lay-search/index.vue +25 -25
- package/src/layout/components/lay-select-org/index.vue +4 -9
- package/src/layout/components/lay-setting/index.vue +503 -510
- package/src/layout/components/lay-sidebar/horizontal.vue +8 -6
- package/src/layout/components/lay-sidebar/mixNav.vue +260 -258
- package/src/layout/components/lay-sidebar/sidebar-logo.vue +101 -98
- package/src/layout/components/lay-tag/index.vue +24 -51
- package/src/layout/hooks/useDataThemeChange.ts +1 -1
- package/src/layout/hooks/useNav.ts +176 -173
- package/src/layout/hooks/useTag.ts +227 -233
- package/src/layout/types.ts +93 -92
- package/src/main.ts +115 -119
- package/src/plugins/i18n/en.ts +302 -302
- package/src/plugins/i18n/module/u-workflow.ts +1 -1
- package/src/plugins/i18n/zh.ts +21 -6
- package/src/plugins/vxe-table/index.ts +116 -53
- package/src/plugins/vxe-table/render.tsx +945 -956
- package/src/router/index.ts +17 -17
- package/src/router/modules/flow.ts +35 -0
- package/src/router/modules/home.ts +32 -32
- package/src/router/modules/remaining.ts +58 -58
- package/src/router/utils.ts +420 -377
- package/src/store/modules/app.ts +2 -4
- package/src/store/modules/epTheme.ts +48 -49
- package/src/store/modules/multiTags.ts +15 -14
- package/src/store/modules/permission.ts +25 -15
- package/src/store/modules/system.ts +1 -3
- package/src/style/button.scss +85 -85
- package/src/style/login.css +1 -1
- package/src/style/vxetable.scss +61 -2
- package/src/utils/dataFormat/index.ts +223 -223
- package/src/utils/index.ts +3 -1
- package/src/utils/lifecycle.ts +39 -20
- package/src/utils/propTypes.ts +1 -6
- package/src/utils/storage/index.ts +2 -2
- package/src/utils/udp/http/index.ts +24 -11
- package/src/utils/udp/http/types.d.ts +3 -10
- package/src/views/login/login-view.vue +4 -18
- package/src/views/organization/company/CompanyPanel.vue +259 -259
- package/src/views/organization/department/Department.vue +58 -58
- package/src/views/organization/department/DepartmentPanel.vue +303 -283
- package/src/views/organization/inv-org/InvOrganization.vue +22 -7
- package/src/views/organization/staff/StaffInfo.vue +127 -133
- package/src/views/organization/staff/StaffPanel.vue +162 -145
- package/src/views/system/cron/cron-task.vue +2 -12
- package/src/views/system/menu/SystemMenu.vue +185 -183
- package/src/views/system/menu/menuInfo.vue +384 -363
- package/src/views/system/role/UserInfo.vue +195 -195
- package/src/views/system/role-assign/RoleAssign.vue +57 -57
- package/src/views/system/role-assign/RolePanel.vue +139 -139
- package/src/views/system/sys/sys-config.vue +69 -20
- package/src/views/system/sysUser/SysUserPanel.vue +97 -28
- package/src/views/uapp/pda/pda-app.vue +208 -208
- package/src/views/udev/coderule/code-rule.vue +132 -121
- package/src/views/udev/dict/DictView.vue +2 -2
- package/src/views/udev/dict/childView.vue +183 -222
- package/src/views/udev/lov/childView.vue +1 -7
- package/src/views/udev/lov/lov-view.vue +91 -91
- package/src/views/uhome/components/menu-favorite.vue +314 -331
- package/src/views/uhome/su-welcome.vue +319 -339
- package/src/views/ulogin/login.vue +325 -321
- package/src/views/upms/interface/log-in.vue +100 -106
- package/src/views/upms/interface/log-out.vue +104 -107
- package/src/views/upms/user/login-log.vue +54 -60
- package/src/views/urpt/design/DesignPanel.vue +507 -507
- package/src/views/urpt/design/Preview.vue +1 -0
- package/src/views/urpt/design/ReportDesign.vue +2 -4
- package/src/views/utask/flow-task.vue +18 -0
- package/types/global.d.ts +231 -236
- package/dist/InvOrganization-BVuOhzbt.js +0 -66
- package/dist/StaffPanel.vue_vue_type_script_setup_true_lang-BOOO6Cek.js +0 -111
- package/dist/SysUserPanel.vue_vue_type_script_setup_true_lang-SwNbAEvW.js +0 -294
- package/dist/childView.vue_vue_type_style_index_0_lang-DWIFCX3X.js +0 -187
- package/dist/index-CKnq5xIa.js +0 -2623
- package/dist/log-out--RRncZhN.js +0 -120
- package/dist/login-CpKykfdf.js +0 -253
- package/dist/sys-config-DiySRWns.js +0 -277
- package/dist/utogether-Dct_14Zk.js +0 -182
- package/src/components/udp/count-down.vue +0 -536
- package/src/components/udp/flip-down/FlipCard/flip-card.vue +0 -251
- package/src/components/udp/flip-down/FlipCard/interfaces.ts +0 -4
- package/src/components/udp/flip-down/FlipClock/flip-clock.vue +0 -113
- package/src/components/udp/form-upload.vue +0 -482
- package/src/components/udp/lov.vue +0 -388
- package/src/components/udp/modal-form.vue +0 -189
- package/src/components/udp/modal-grid.vue +0 -288
- package/src/components/udp/upload.vue +0 -423
- package/src/utils/udp/useRender.ts +0 -431
|
@@ -1,339 +1,319 @@
|
|
|
1
|
-
<!--
|
|
2
|
-
* @Author: levi7754 levi7754@163.com
|
|
3
|
-
* @Date: 2023-11-02 10:04:05
|
|
4
|
-
* @LastEditors: levi7754 levi7754@163.com
|
|
5
|
-
* @LastEditTime: 2025-
|
|
6
|
-
* @FilePath: /front-web-mes/src/views/uhome/su-welcome.vue
|
|
7
|
-
* @Description: 欢迎页面
|
|
8
|
-
-->
|
|
9
|
-
<template>
|
|
10
|
-
<div class="ut-home m-3">
|
|
11
|
-
<!-- 顶部 -->
|
|
12
|
-
<div class="h-32 mb-4 p-4 flex justify-between items-center bg-white home-page">
|
|
13
|
-
<div class="flex flex-row items-center flex-[2]">
|
|
14
|
-
<div>
|
|
15
|
-
<el-avatar size="large" class="text-4xl font-bold bg-[var(--el-color-primary)]">{{
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
>
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
<
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
</
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
>
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
const
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
const
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
const
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
const
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
const
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
.el-avatar--large {
|
|
321
|
-
--el-avatar-size: 72px;
|
|
322
|
-
}
|
|
323
|
-
|
|
324
|
-
::v-deep(.el-card__body) {
|
|
325
|
-
padding: 0 !important;
|
|
326
|
-
}
|
|
327
|
-
}
|
|
328
|
-
|
|
329
|
-
// .u-dashed-menu {
|
|
330
|
-
// li {
|
|
331
|
-
// box-shadow: 1px 0 0 0 #e8e8e8, 0 1px 0 0 #e8e8e8, 1px 1px 0 0 #e8e8e8, 1px 0 0 0 #e8e8e8 inset,
|
|
332
|
-
// 0 1px 0 0 #e8e8e8 inset;
|
|
333
|
-
// }
|
|
334
|
-
|
|
335
|
-
// li:hover {
|
|
336
|
-
// box-shadow: 0 2px 8px rgb(0 0 0 / 15%);
|
|
337
|
-
// }
|
|
338
|
-
// }
|
|
339
|
-
</style>
|
|
1
|
+
<!--
|
|
2
|
+
* @Author: levi7754 levi7754@163.com
|
|
3
|
+
* @Date: 2023-11-02 10:04:05
|
|
4
|
+
* @LastEditors: levi7754 levi7754@163.com
|
|
5
|
+
* @LastEditTime: 2025-12-02 18:28:17
|
|
6
|
+
* @FilePath: /front-web-mes/src/views/uhome/su-welcome.vue
|
|
7
|
+
* @Description: 欢迎页面
|
|
8
|
+
-->
|
|
9
|
+
<template>
|
|
10
|
+
<div class="ut-home m-3">
|
|
11
|
+
<!-- 顶部 -->
|
|
12
|
+
<div class="h-32 mb-4 p-4 flex justify-between items-center bg-white home-page">
|
|
13
|
+
<div class="flex flex-row items-center flex-[2]">
|
|
14
|
+
<div>
|
|
15
|
+
<el-avatar size="large" class="text-4xl font-bold bg-[var(--el-color-primary)]">{{ firstName }}</el-avatar>
|
|
16
|
+
</div>
|
|
17
|
+
<div class="ml-4 text-xs flex-[2]">
|
|
18
|
+
<div class="flex justify-center items-center">
|
|
19
|
+
<span> {{ getCurrentPeriod() }}, {{ systemHook.getUserInfo?.name || '' }},欢迎回来! </span>
|
|
20
|
+
<div class="flex flex-[2] justify-center items-center font-bold" style="color: var(--el-color-primary)">
|
|
21
|
+
星光不问赶路人,岁月不负有心人,以梦为马,不负韶华!
|
|
22
|
+
</div>
|
|
23
|
+
</div>
|
|
24
|
+
<div class="py-2 text-gray-500 flex">
|
|
25
|
+
<span class="inline-block"> 所属角色: </span>
|
|
26
|
+
<div class="w-2/3">{{ getRole() }}</div>
|
|
27
|
+
</div>
|
|
28
|
+
<div class="text-gray-500 flex">
|
|
29
|
+
<span class="inline-block"> 所属组织: </span>
|
|
30
|
+
<div class="w-2/3">{{ getOrg() }}</div>
|
|
31
|
+
</div>
|
|
32
|
+
</div>
|
|
33
|
+
</div>
|
|
34
|
+
<div class="flex flex-col">
|
|
35
|
+
<span class="text-4xl">
|
|
36
|
+
<ut-flip-down :show-days="false" :show-labels="false" />
|
|
37
|
+
</span>
|
|
38
|
+
<div class="mt-1 ml-3">{{ getLunarDay() }}</div>
|
|
39
|
+
</div>
|
|
40
|
+
</div>
|
|
41
|
+
<!-- 底部 -->
|
|
42
|
+
<el-row class="m-2" :gutter="10">
|
|
43
|
+
<el-col v-spinning="loading" :lg="24" :md="24" class="">
|
|
44
|
+
<el-card class="mb-2">
|
|
45
|
+
<template #header>
|
|
46
|
+
<div class="flex items-center justify-between dark:bg-black">
|
|
47
|
+
<span class="font-bold">常用菜单</span>
|
|
48
|
+
<span class="text-xs text-gray-400 cursor-pointer" @click="onFavoriteMenu">
|
|
49
|
+
<span>更多</span>
|
|
50
|
+
<i class="vxe-icon-arrow-right" />
|
|
51
|
+
</span>
|
|
52
|
+
</div>
|
|
53
|
+
</template>
|
|
54
|
+
|
|
55
|
+
<div class="default:bg-white dark:bg-black">
|
|
56
|
+
<el-empty v-if="!menuList.length" :image-size="100" description="快来添加常用菜单吧!" class="p-0 pb-3" />
|
|
57
|
+
<ul
|
|
58
|
+
class="p-0 w-full h-full grid grid-rows-1 grid-cols-8 u-dashed-menu"
|
|
59
|
+
:class="{ 'grid-rows-2': menuList.length > 8 }"
|
|
60
|
+
>
|
|
61
|
+
<li
|
|
62
|
+
v-for="(item, idx) in menuList"
|
|
63
|
+
:key="item.id"
|
|
64
|
+
class="text-center list-none bg-white"
|
|
65
|
+
@click="onClickMenu(item)"
|
|
66
|
+
>
|
|
67
|
+
<div class="h-20 flex justify-center items-center flex-col">
|
|
68
|
+
<div
|
|
69
|
+
class="rounded-full w-10 h-10 flex items-center justify-center"
|
|
70
|
+
:style="{ backgroundColor: getColor(idx) }"
|
|
71
|
+
>
|
|
72
|
+
<iconify-icon-offline :icon="item.icon || `ri:${icons[idx]}-line`" class="text-2xl text-white" />
|
|
73
|
+
</div>
|
|
74
|
+
<span class="text-xs mt-2">{{ item.menuName }}</span>
|
|
75
|
+
</div>
|
|
76
|
+
</li>
|
|
77
|
+
</ul>
|
|
78
|
+
</div>
|
|
79
|
+
<div />
|
|
80
|
+
</el-card>
|
|
81
|
+
</el-col>
|
|
82
|
+
|
|
83
|
+
<el-col :xl="16" :lg="12" :md="24">
|
|
84
|
+
<el-card class="mb-2">
|
|
85
|
+
<template #header>
|
|
86
|
+
<div class="font-bold">
|
|
87
|
+
<span>个人动态</span>
|
|
88
|
+
</div>
|
|
89
|
+
</template>
|
|
90
|
+
<div class="p-3">
|
|
91
|
+
<ul class="p-0 w-full h-full">
|
|
92
|
+
<li v-for="item in logList" :key="item.id" class="w-full list-none p-2 border-b border-gray-200">
|
|
93
|
+
<div class="flex">
|
|
94
|
+
<div>
|
|
95
|
+
<el-avatar class="text-base">{{ firstName }}</el-avatar>
|
|
96
|
+
</div>
|
|
97
|
+
<div class="ml-3">
|
|
98
|
+
<div>
|
|
99
|
+
<span class="text-blue-600 mr-3">{{ item.browser }}</span>
|
|
100
|
+
<span>{{ item.browserVersion || item.platformVersion }}</span>
|
|
101
|
+
</div>
|
|
102
|
+
<div class="text-gray-400 text-sm">{{ item.loginTime }}</div>
|
|
103
|
+
</div>
|
|
104
|
+
</div>
|
|
105
|
+
</li>
|
|
106
|
+
</ul>
|
|
107
|
+
</div>
|
|
108
|
+
</el-card>
|
|
109
|
+
</el-col>
|
|
110
|
+
|
|
111
|
+
<!-- 右侧 -->
|
|
112
|
+
<el-col :xl="8" :lg="12" :md="24" class="">
|
|
113
|
+
<el-card class="mb-2">
|
|
114
|
+
<template #header>
|
|
115
|
+
<div class="font-bold">
|
|
116
|
+
<span>日历</span>
|
|
117
|
+
</div>
|
|
118
|
+
</template>
|
|
119
|
+
<div class="p-1">
|
|
120
|
+
<ut-calendar :holidays="holidays" :statutory-holiday="statutoryHoliday" />
|
|
121
|
+
</div>
|
|
122
|
+
</el-card>
|
|
123
|
+
</el-col>
|
|
124
|
+
</el-row>
|
|
125
|
+
<menu-favorite
|
|
126
|
+
v-if="showFavorite"
|
|
127
|
+
:data-source="menuList"
|
|
128
|
+
:user-name="systemHook.getUserInfo.userName"
|
|
129
|
+
:icons="icons"
|
|
130
|
+
@close="showFavorite = false"
|
|
131
|
+
@success="getMenuList"
|
|
132
|
+
/>
|
|
133
|
+
</div>
|
|
134
|
+
</template>
|
|
135
|
+
|
|
136
|
+
<script setup lang="ts">
|
|
137
|
+
import { ref, onMounted, computed } from 'vue';
|
|
138
|
+
import { useRouter } from 'vue-router';
|
|
139
|
+
import dayjs from 'dayjs';
|
|
140
|
+
import { lunarCalendar, cookies } from '@utogether/utils';
|
|
141
|
+
import { useSystemStoreHook } from '../../store/modules/system';
|
|
142
|
+
import { getServiceApi } from '../../api';
|
|
143
|
+
import { kLOGINER } from '../../contant';
|
|
144
|
+
import menuFavorite from './components/menu-favorite.vue';
|
|
145
|
+
|
|
146
|
+
defineOptions({ name: 'UdpWelcome' });
|
|
147
|
+
|
|
148
|
+
const systemHook = useSystemStoreHook();
|
|
149
|
+
const router = useRouter();
|
|
150
|
+
|
|
151
|
+
const menuList = ref([]);
|
|
152
|
+
const logList = ref([]);
|
|
153
|
+
const showFavorite = ref(false);
|
|
154
|
+
const loading = ref(false);
|
|
155
|
+
|
|
156
|
+
const firstName = computed(() => {
|
|
157
|
+
return systemHook.getUserInfo.name?.slice(0, 1);
|
|
158
|
+
});
|
|
159
|
+
|
|
160
|
+
// 角色
|
|
161
|
+
const getRole = () => {
|
|
162
|
+
const isAdmin = systemHook.isAdminRole;
|
|
163
|
+
if (isAdmin) {
|
|
164
|
+
return '系统管理员';
|
|
165
|
+
} else {
|
|
166
|
+
return systemHook.getUserInfo?.sysRoles?.map(m => m.roleName).join(',');
|
|
167
|
+
}
|
|
168
|
+
};
|
|
169
|
+
|
|
170
|
+
// 组织
|
|
171
|
+
const getOrg = () => {
|
|
172
|
+
const isAdmin = systemHook.isAdminRole;
|
|
173
|
+
if (isAdmin) {
|
|
174
|
+
return '【系统管理员】拥有所有组织';
|
|
175
|
+
} else {
|
|
176
|
+
if (getRole() === '项目组管理员') {
|
|
177
|
+
return '【项目组管理员】拥有所有组织';
|
|
178
|
+
}
|
|
179
|
+
return systemHook.getOrglist?.map(m => m.orgName).join(',');
|
|
180
|
+
}
|
|
181
|
+
};
|
|
182
|
+
|
|
183
|
+
// 获取时间段
|
|
184
|
+
const getCurrentPeriod = () => {
|
|
185
|
+
const hour = Number(dayjs().format('HH'));
|
|
186
|
+
return hour < 12 ? '上午好' : hour < 18 ? '下午好' : '晚上好';
|
|
187
|
+
};
|
|
188
|
+
|
|
189
|
+
const getLunarDay = () => {
|
|
190
|
+
const time = new Date();
|
|
191
|
+
const lunarday = lunarCalendar.solar2lunar(time.getFullYear(), time.getMonth() + 1, time.getDate()) as IRecord;
|
|
192
|
+
const { gzYear, IMonthCn, IDayCn, cMonth, cDay, ncWeek } = lunarday;
|
|
193
|
+
return `${cMonth}月${cDay}日 ${gzYear}${IMonthCn}${IDayCn} ${ncWeek}`;
|
|
194
|
+
};
|
|
195
|
+
|
|
196
|
+
/** 查询收藏菜单功能 */
|
|
197
|
+
const getMenuList = () => {
|
|
198
|
+
const url = '/upfm/v1/menuFavority';
|
|
199
|
+
loading.value = true;
|
|
200
|
+
const query = { pageSize: 20, pageNum: 1, userName: cookies.get(kLOGINER) };
|
|
201
|
+
getServiceApi()
|
|
202
|
+
.get(url, query)
|
|
203
|
+
.then((res: IResponseData) => {
|
|
204
|
+
menuList.value = res?.list || [];
|
|
205
|
+
})
|
|
206
|
+
.finally(() => {
|
|
207
|
+
loading.value = false;
|
|
208
|
+
});
|
|
209
|
+
};
|
|
210
|
+
|
|
211
|
+
const onClickMenu = item => {
|
|
212
|
+
router.push(item.menuPath);
|
|
213
|
+
};
|
|
214
|
+
|
|
215
|
+
const getUserLog = () => {
|
|
216
|
+
const url = '/upfm/v1/userMonitor';
|
|
217
|
+
const query = { pageSize: 8, pageNum: 1, employeeName: systemHook.getUserInfo?.name };
|
|
218
|
+
getServiceApi()
|
|
219
|
+
.get(url, query)
|
|
220
|
+
.then((res: IResponseData) => {
|
|
221
|
+
logList.value = res?.list || [];
|
|
222
|
+
});
|
|
223
|
+
};
|
|
224
|
+
|
|
225
|
+
const onFavoriteMenu = () => {
|
|
226
|
+
showFavorite.value = true;
|
|
227
|
+
};
|
|
228
|
+
|
|
229
|
+
onMounted(() => {
|
|
230
|
+
getMenuList();
|
|
231
|
+
getUserLog();
|
|
232
|
+
});
|
|
233
|
+
|
|
234
|
+
const getColor = idx => {
|
|
235
|
+
const colorSet = ['#409eff', '#67c23a', '#13c2c2', '#e85f33', 'orange'];
|
|
236
|
+
return colorSet[idx % 5];
|
|
237
|
+
};
|
|
238
|
+
|
|
239
|
+
const icons = [
|
|
240
|
+
'community',
|
|
241
|
+
'shield-star',
|
|
242
|
+
'group',
|
|
243
|
+
'settings',
|
|
244
|
+
'star',
|
|
245
|
+
'train',
|
|
246
|
+
'send-plane',
|
|
247
|
+
'rocket',
|
|
248
|
+
'device',
|
|
249
|
+
'compass',
|
|
250
|
+
'map-pin',
|
|
251
|
+
'keynote',
|
|
252
|
+
'article',
|
|
253
|
+
'tv',
|
|
254
|
+
'database-2',
|
|
255
|
+
'calendar'
|
|
256
|
+
];
|
|
257
|
+
|
|
258
|
+
// 假期设置
|
|
259
|
+
const holidays = [
|
|
260
|
+
{
|
|
261
|
+
2023: { 12: { 30: '班', 31: '班' } }
|
|
262
|
+
},
|
|
263
|
+
{
|
|
264
|
+
2024: {
|
|
265
|
+
1: { 1: '假' },
|
|
266
|
+
2: {
|
|
267
|
+
4: '班',
|
|
268
|
+
10: '假',
|
|
269
|
+
11: '假',
|
|
270
|
+
12: '假',
|
|
271
|
+
13: '假',
|
|
272
|
+
14: '假',
|
|
273
|
+
15: '假',
|
|
274
|
+
16: '假',
|
|
275
|
+
17: '假',
|
|
276
|
+
18: '班'
|
|
277
|
+
},
|
|
278
|
+
4: { 4: '假', 5: '假', 6: '假', 7: '班', 28: '班' },
|
|
279
|
+
5: { 1: '假', 2: '假', 3: '假', 4: '假', 5: '假', 11: '班' },
|
|
280
|
+
6: { 8: '假', 9: '假', 10: '假' },
|
|
281
|
+
9: { 15: '假', 16: '假', 17: '假', 14: '班', 29: '班' },
|
|
282
|
+
10: { 1: '假', 2: '假', 3: '假', 4: '假', 5: '假', 6: '假', 7: '假', 12: '班' }
|
|
283
|
+
}
|
|
284
|
+
}
|
|
285
|
+
];
|
|
286
|
+
// 法定假日;
|
|
287
|
+
const statutoryHoliday = [
|
|
288
|
+
{ name: '元旦', date: '2024-01-01' },
|
|
289
|
+
{ name: '春节', date: '2024-02-10' },
|
|
290
|
+
{ name: '清明节', date: '2024-04-04' },
|
|
291
|
+
{ name: '劳动节', date: '2024-05-01' },
|
|
292
|
+
{ name: '端午节', date: '2024-06-10' },
|
|
293
|
+
{ name: '中秋节', date: '2024-09-17' },
|
|
294
|
+
{ name: '国庆节', date: '2024-10-01' }
|
|
295
|
+
];
|
|
296
|
+
</script>
|
|
297
|
+
|
|
298
|
+
<style lang="scss" scoped>
|
|
299
|
+
.ut-home {
|
|
300
|
+
.el-avatar--large {
|
|
301
|
+
--el-avatar-size: 72px;
|
|
302
|
+
}
|
|
303
|
+
|
|
304
|
+
::v-deep(.el-card__body) {
|
|
305
|
+
padding: 0 !important;
|
|
306
|
+
}
|
|
307
|
+
}
|
|
308
|
+
|
|
309
|
+
// .u-dashed-menu {
|
|
310
|
+
// li {
|
|
311
|
+
// box-shadow: 1px 0 0 0 #e8e8e8, 0 1px 0 0 #e8e8e8, 1px 1px 0 0 #e8e8e8, 1px 0 0 0 #e8e8e8 inset,
|
|
312
|
+
// 0 1px 0 0 #e8e8e8 inset;
|
|
313
|
+
// }
|
|
314
|
+
|
|
315
|
+
// li:hover {
|
|
316
|
+
// box-shadow: 0 2px 8px rgb(0 0 0 / 15%);
|
|
317
|
+
// }
|
|
318
|
+
// }
|
|
319
|
+
</style>
|