@utogether/udp-core 1.0.1-beta.1 → 1.0.1-beta.11

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.
Files changed (147) hide show
  1. package/build/plugins.ts +39 -32
  2. package/dist/{403-Dp617CWX.js → 403-Dsgsr2M-.js} +1 -1
  3. package/dist/{404-Cz_Axb6Y.js → 404-DmPHEfqM.js} +1 -1
  4. package/dist/{500-BGCtRNse.js → 500-OYEgHR2a.js} +1 -1
  5. package/dist/{AuthorityInfo-DGGfm7IS.js → AuthorityInfo-B1H1txG-.js} +1 -1
  6. package/dist/AuthorityInfo.vue_vue_type_style_index_0_lang-BUlmQtjQ.js +100 -0
  7. package/dist/{Company-IV3GTnzY.js → Company-C8ojgx93.js} +3 -3
  8. package/dist/{CompanyPanel-qV-_VtoL.js → CompanyPanel-Dageer1t.js} +16 -16
  9. package/dist/{Department-B3W-OxW8.js → Department-Dr94_85I.js} +3 -3
  10. package/dist/{DepartmentPanel-Cw3OWxE7.js → DepartmentPanel-Bc5r1HpT.js} +1 -1
  11. package/dist/{DesignPanel-BFxR2fHJ.js → DesignPanel-CcWt1Myp.js} +1 -1
  12. package/dist/{DesignPanel.vue_vue_type_style_index_0_lang-DljbeFba.js → DesignPanel.vue_vue_type_style_index_0_lang-CKA6nx1l.js} +24 -26
  13. package/dist/DictView-BHj6wexC.js +110 -0
  14. package/dist/InvOrganization-DP3Le9g-.js +72 -0
  15. package/dist/Org-BRGHTwsw.js +39 -0
  16. package/dist/{Preview-BlDMmpdR.js → Preview-CqMaUD_3.js} +1 -1
  17. package/dist/{ReportDefine-Cub_85LA.js → ReportDefine-PEQdTCOY.js} +1 -1
  18. package/dist/{ReportDesign-hFhq5UVE.js → ReportDesign-CB4bv8ba.js} +43 -43
  19. package/dist/{ReportQuery-ChkWEyxT.js → ReportQuery-B7t4lMK0.js} +1 -1
  20. package/dist/{ReportQueryFrom-KVyD_8Dj.js → ReportQueryFrom-VBxUIMRJ.js} +1 -1
  21. package/dist/{ReportQueryFrom.vue_vue_type_style_index_0_lang-CLNODquq.js → ReportQueryFrom.vue_vue_type_style_index_0_lang-HeLA4Qs5.js} +1 -1
  22. package/dist/{ReportTemplate-ag9NDvh2.js → ReportTemplate-DNkv7F5p.js} +28 -28
  23. package/dist/{Role-_q3lQ8CZ.js → Role-BGfTpZK4.js} +6 -6
  24. package/dist/{RoleAssign-DZb9IRsm.js → RoleAssign-DrKFWZzA.js} +8 -8
  25. package/dist/{RolePanel-CsLsz-Ds.js → RolePanel-3lvRh7aS.js} +1 -1
  26. package/dist/{RolePanel-BQb1LlhD.js → RolePanel-BRI5QYe4.js} +1 -1
  27. package/dist/RolePanel.vue_vue_type_script_setup_true_lang-BXKZb7yt.js +132 -0
  28. package/dist/{RolePanel.vue_vue_type_script_setup_true_lang-BrnRgHEk.js → RolePanel.vue_vue_type_script_setup_true_lang-Cci_Ysty.js} +44 -38
  29. package/dist/{ScrollPanel.vue_vue_type_style_index_0_lang-CaFKRwXu.js → ScrollPanel.vue_vue_type_style_index_0_lang-BmId6zzA.js} +21 -21
  30. package/dist/{Staff-BSf9Ypbk.js → Staff-Dr0dq3fW.js} +3 -3
  31. package/dist/{StaffInfo-BNKasyMF.js → StaffInfo-_N9g2hPa.js} +1 -1
  32. package/dist/{StaffInfo.vue_vue_type_script_setup_true_lang-DDZ7ukd0.js → StaffInfo.vue_vue_type_script_setup_true_lang-DiTJY2ug.js} +11 -11
  33. package/dist/{StaffPanel-Bpq0WVlH.js → StaffPanel-mxJQiW3G.js} +1 -1
  34. package/dist/{StaffPanel.vue_vue_type_script_setup_true_lang-BhiJ0Q-Q.js → StaffPanel.vue_vue_type_script_setup_true_lang-GRGn-5t6.js} +2 -2
  35. package/dist/{SysUser-FAABuNti.js → SysUser-DgA19hZE.js} +2 -2
  36. package/dist/{SysUserPanel-PxJeOgHm.js → SysUserPanel-Bc85z5_K.js} +1 -1
  37. package/dist/SysUserPanel.vue_vue_type_script_setup_true_lang-BHDrP1Pk.js +294 -0
  38. package/dist/{SystemMenu-C-7NAGon.js → SystemMenu-Be-gFIie.js} +26 -26
  39. package/dist/{UserInfo-ClXKtyGo.js → UserInfo-BCYuwFmr.js} +1 -1
  40. package/dist/{UserInfo.vue_vue_type_style_index_0_lang-8N7P4Hl7.js → UserInfo.vue_vue_type_style_index_0_lang-B1lgokO6.js} +39 -37
  41. package/dist/{childView-C_HmDQNd.js → childView-DhcBr1UA.js} +1 -1
  42. package/dist/{childView-uUlBcTza.js → childView-Dk4zZoXd.js} +1 -1
  43. package/dist/{childView.vue_vue_type_style_index_0_lang-Ckjmw6wJ.js → childView.vue_vue_type_style_index_0_lang-CVnLnl03.js} +40 -40
  44. package/dist/{childView.vue_vue_type_style_index_0_lang-y0sDvYx5.js → childView.vue_vue_type_style_index_0_lang-D4GYVhOc.js} +1 -1
  45. package/dist/{code-rule-AgCVDKFy.js → code-rule-BSwPwuAL.js} +9 -10
  46. package/dist/core.es.js +14 -11
  47. package/dist/{cron-task-C6FgQxTi.js → cron-task-T1ztyra7.js} +1 -1
  48. package/dist/{frameView-BDgISK7N.js → frameView-BDgngiBq.js} +1 -1
  49. package/dist/img/l_img.svg +1 -1
  50. package/dist/img/minicolors.png +0 -0
  51. package/dist/img/v_img.svg +1 -1
  52. package/dist/index-BSj2AtVL.js +4468 -0
  53. package/dist/{layoutView-yb3DV2DQ.js → layoutView-i7dLLBzJ.js} +1181 -1176
  54. package/dist/{login-RRpljbkm.js → login-K5Ludp8x.js} +105 -113
  55. package/dist/{login-log-CvVnyGi3.js → login-log-kqKzKTto.js} +1 -1
  56. package/dist/{lov-view-C9-rjzZR.js → lov-view-lAexiucu.js} +2 -2
  57. package/dist/{menuInfo-CzPQyFhp.js → menuInfo-BaN5YZPp.js} +1 -1
  58. package/dist/{menuInfo.vue_vue_type_style_index_0_lang-BumXunCg.js → menuInfo.vue_vue_type_style_index_0_lang-yI4QOYxG.js} +100 -97
  59. package/dist/{pda-app-Dvy3U-b6.js → pda-app-DEtDXFvM.js} +211 -197
  60. package/dist/{resource-Fy0lFkSV.js → resource-Bztmz7pn.js} +15 -15
  61. package/dist/{su-welcome-DYvSCUST.js → su-welcome-Bx8nBPi9.js} +109 -110
  62. package/dist/sys-config-nvrtYGgi.js +290 -0
  63. package/dist/udp-core.css +2 -2
  64. package/dist/{utogether-CjmJiHoE.js → utogether-yPnwDAIH.js} +1 -1
  65. package/index.ts +40 -36
  66. package/package.json +18 -18
  67. package/src/App.vue +65 -70
  68. package/src/api/index.ts +31 -31
  69. package/src/components/SuCharts/src/UserInfo.vue +78 -78
  70. package/src/components/SuScrollTree/ScrollPanel.vue +3 -3
  71. package/src/components/udp/count-down.vue +536 -0
  72. package/src/components/udp/flip-down/FlipCard/flip-card.vue +251 -0
  73. package/src/components/udp/flip-down/FlipCard/interfaces.ts +4 -0
  74. package/src/components/udp/flip-down/FlipClock/flip-clock.vue +113 -0
  75. package/src/components/udp/form-upload.vue +414 -64
  76. package/src/components/udp/form.vue +112 -0
  77. package/src/components/udp/grid.vue +495 -0
  78. package/src/components/udp/index.ts +10 -4
  79. package/src/components/udp/lov.vue +388 -0
  80. package/src/components/udp/modal-form.vue +13 -3
  81. package/src/components/udp/modal-grid.vue +298 -0
  82. package/src/components/udp/upload.vue +423 -0
  83. package/src/components/udp/utils.ts +447 -40
  84. package/src/directives/permission/index.ts +1 -1
  85. package/src/layout/components/lay-navbar/index.vue +239 -237
  86. package/src/layout/components/lay-panel/index.vue +150 -150
  87. package/src/layout/components/lay-search/index.vue +25 -25
  88. package/src/layout/components/lay-select-org/index.vue +64 -69
  89. package/src/layout/components/lay-sidebar/breadCrumb.vue +1 -1
  90. package/src/layout/components/lay-sidebar/horizontal.vue +190 -191
  91. package/src/layout/components/lay-sidebar/mixNav.vue +260 -258
  92. package/src/layout/components/lay-sidebar/sidebar-logo.vue +92 -98
  93. package/src/layout/components/lay-tag/index.vue +625 -625
  94. package/src/layout/hooks/useNav.ts +173 -173
  95. package/src/layout/layoutView.vue +215 -215
  96. package/src/main.ts +119 -109
  97. package/src/plugins/i18n/en.ts +302 -289
  98. package/src/plugins/i18n/zh.ts +349 -337
  99. package/src/plugins/vxe-table/index.ts +53 -46
  100. package/src/plugins/vxe-table/render.tsx +956 -817
  101. package/src/router/index.ts +177 -183
  102. package/src/router/modules/remaining.ts +58 -83
  103. package/src/store/modules/permission.ts +1 -4
  104. package/src/style/button.scss +85 -78
  105. package/src/style/tailwind.css +1 -68
  106. package/src/style/vxetable.scss +44 -11
  107. package/src/utils/authority/index.ts +1 -1
  108. package/src/utils/{http → udp/http}/index.ts +283 -297
  109. package/src/utils/{http → udp/http}/types.d.ts +8 -5
  110. package/src/utils/udp/useRender.ts +17 -6
  111. package/src/views/login/login-view.vue +300 -314
  112. package/src/views/organization/company/CompanyPanel.vue +259 -259
  113. package/src/views/organization/inv-org/InvOrganization.vue +68 -54
  114. package/src/views/organization/org/Org.vue +9 -5
  115. package/src/views/system/menu/SystemMenu.vue +183 -197
  116. package/src/views/system/menu/menuInfo.vue +363 -371
  117. package/src/views/system/role/AuthorityInfo.vue +19 -15
  118. package/src/views/system/role/Role.vue +1 -5
  119. package/src/views/system/role/RolePanel.vue +11 -2
  120. package/src/views/system/role/UserInfo.vue +195 -193
  121. package/src/views/system/role-assign/RoleAssign.vue +57 -57
  122. package/src/views/system/role-assign/RolePanel.vue +139 -136
  123. package/src/views/system/sys/sys-config.vue +287 -291
  124. package/src/views/system/sysUser/SysUserPanel.vue +278 -278
  125. package/src/views/uapp/pda/pda-app.vue +208 -176
  126. package/src/views/udev/dict/DictView.vue +118 -106
  127. package/src/views/udev/dict/childView.vue +7 -7
  128. package/src/views/udev/lov/lov-view.vue +91 -91
  129. package/src/views/ufile/aggregation/File.vue +5 -5
  130. package/src/views/ufile/file/water-mark.vue +14 -14
  131. package/src/views/uhome/su-welcome.vue +3 -3
  132. package/src/views/ulogin/login.vue +12 -8
  133. package/src/views/upms/user/login-log.vue +1 -1
  134. package/src/views/urpt/design/DesignPanel.vue +507 -526
  135. package/src/views/urpt/design/ReportDesign.vue +15 -19
  136. package/src/views/urpt/static-resource/resource.vue +3 -3
  137. package/src/views/urpt/template/ReportTemplate.vue +7 -7
  138. package/types/global.d.ts +2 -1
  139. package/vite.config.ts +6 -2
  140. package/dist/AuthorityInfo.vue_vue_type_style_index_0_lang-BqccGW7v.js +0 -102
  141. package/dist/DictView-C-i7e4hZ.js +0 -95
  142. package/dist/InvOrganization-cfT6riGU.js +0 -260
  143. package/dist/Org-CA7vTDIF.js +0 -35
  144. package/dist/RolePanel.vue_vue_type_script_setup_true_lang-cmW7zBLu.js +0 -126
  145. package/dist/SysUserPanel.vue_vue_type_script_setup_true_lang-njefUln5.js +0 -288
  146. package/dist/index-DzOzUkf6.js +0 -3388
  147. package/dist/sys-config-DJ1vNQTy.js +0 -277
@@ -1,191 +1,190 @@
1
- <script setup lang="ts">
2
- import { ref, nextTick } from 'vue';
3
- import { storageLocal } from '@utogether/utils';
4
- import { useNav } from '../../hooks/useNav';
5
- import OrgSelect from '../lay-select-org/index.vue';
6
- import Search from '../lay-search/index.vue';
7
- // import Notice from '../lay-notice/index.vue';
8
- import SidebarItem from './sidebarItem.vue';
9
- import avatars from '../../../assets/images/avatars.jpg';
10
- import { kSYSCONFIG } from '../../../contant';
11
- import { useTranslationLang } from '../../hooks/useTranslationLang';
12
- import globalization from '../../../assets/svg/globalization.svg?component';
13
-
14
- import utogether from '../../../assets/images/utogether.png';
15
- import { usePermissionStoreHook } from '../../../store/modules/permission';
16
-
17
- const menuRef = ref();
18
- const { route, locale, translationCh, translationEn } = useTranslationLang(menuRef);
19
- const routeStore = usePermissionStoreHook();
20
-
21
- const sysConfig = storageLocal.getItem(kSYSCONFIG) || {};
22
-
23
- const logo = ref(sysConfig['logo'] || utogether);
24
- const {
25
- title,
26
- logout,
27
- backHome,
28
- onPanel,
29
- userInfo,
30
- avatarsStyle,
31
- getDropdownItemStyle,
32
- getDropdownItemClass,
33
- passwordItems
34
- } = useNav();
35
-
36
- const record: IRecord = {};
37
-
38
- const refScrollbar = ref(null);
39
- const showModal = ref(false);
40
-
41
- nextTick(() => {
42
- menuRef.value?.handleResize();
43
- });
44
-
45
- /**
46
- * @description: 重置密码
47
- */
48
- const handleResetPwd = (): void => {
49
- record.id = userInfo['id'];
50
- showModal.value = true;
51
- };
52
-
53
- const handleScroll = e => {
54
- const wheelDelta = e.wheelDelta || -e.deltaY * 40;
55
- const scrollbar = refScrollbar.value;
56
- // scrollbar.wrap$获取到包裹容器的element对象
57
- scrollbar.setScrollLeft(scrollbar.wrapRef.scrollLeft + wheelDelta);
58
- };
59
- </script>
60
- <script lang="ts">
61
- export default { name: 'LayoutHorizontal' };
62
- </script>
63
- <template>
64
- <div v-spinning="usePermissionStoreHook().wholeMenus.length === 0" class="horizontal-header">
65
- <div class="flex flex-1 horizontal-header-left" @click="backHome">
66
- <img :src="logo" class="h-full" />
67
- <span class="text-xl u-project-text">{{ title }}</span>
68
- </div>
69
- <el-scrollbar ref="refScrollbar" class="flex-[3]" @wheel.prevent="handleScroll">
70
- <template #default>
71
- <el-menu
72
- :default-active="route.path"
73
- :ellipsis="false"
74
- unique-opened
75
- router
76
- popper-class="udp-scrollbar"
77
- class="horizontal-header-menu"
78
- mode="horizontal"
79
- >
80
- <sidebar-item
81
- v-for="route in routeStore.wholeMenus"
82
- :key="route.path"
83
- :item="route"
84
- :base-path="route.path"
85
- />
86
- </el-menu>
87
- </template>
88
- </el-scrollbar>
89
- <div class="horizontal-header-right flex-[2]">
90
- <!-- 业务单元选择 -->
91
- <OrgSelect class="udp-horizontal" />
92
- <!-- 菜单搜索 -->
93
- <Search />
94
- <!-- 通知 -->
95
- <!-- <Notice id="header-notice" /> -->
96
- <!-- 国际化 -->
97
- <el-dropdown id="header-translation" trigger="click">
98
- <globalization
99
- class="navbar-bg-hover w-[40px] h-[48px] p-[11px] cursor-pointer outline-hidden"
100
- />
101
- <template #dropdown>
102
- <el-dropdown-menu class="translation">
103
- <el-dropdown-item
104
- :style="getDropdownItemStyle(locale, 'zh')"
105
- :class="['dark:text-white!', getDropdownItemClass(locale, 'zh')]"
106
- @click="translationCh"
107
- >
108
- <span v-show="locale === 'zh'" class="check-zh">
109
- <IconifyIconOffline icon="check" />
110
- </span>
111
- 简体中文
112
- </el-dropdown-item>
113
- <el-dropdown-item
114
- :style="getDropdownItemStyle(locale, 'en')"
115
- :class="['dark:text-white!', getDropdownItemClass(locale, 'en')]"
116
- @click="translationEn"
117
- >
118
- <span v-show="locale === 'en'" class="check-en">
119
- <IconifyIconOffline icon="check" />
120
- </span>
121
- English
122
- </el-dropdown-item>
123
- </el-dropdown-menu>
124
- </template>
125
- </el-dropdown>
126
- <!-- 退出登录 -->
127
- <el-dropdown trigger="click">
128
- <span class="el-dropdown-link navbar-bg-hover">
129
- <img v-if="avatars" :src="avatars" :style="avatarsStyle" />
130
- <p class="dark:text-white">{{ userInfo.name }}</p>
131
- </span>
132
- <template #dropdown>
133
- <el-dropdown-menu class="user-dropdown">
134
- <el-dropdown-item @click="handleResetPwd">
135
- <IconifyIconOffline icon="edit" />
136
- {{ $t('message.udp.passwordReset') }}</el-dropdown-item
137
- >
138
- <el-divider style="margin: 3px 0 !important" />
139
- <el-dropdown-item @click="logout">
140
- <IconifyIconOffline icon="switch-button" />
141
- {{ $t('message.udp.logout') }}
142
- </el-dropdown-item>
143
- </el-dropdown-menu>
144
- </template>
145
- </el-dropdown>
146
- <span class="el-icon-setting navbar-bg-hover" @click="onPanel">
147
- <IconifyIconOffline icon="ri:settings-5-fill" />
148
- </span>
149
- </div>
150
- <ut-modal-form
151
- v-if="showModal"
152
- :record="record"
153
- :items="passwordItems()"
154
- :width="360"
155
- :height="240"
156
- :title="$t('message.udp.passwordReset')"
157
- data-status="update"
158
- url="/user/updatePwd"
159
- method="put"
160
- @close="showModal = false"
161
- />
162
- </div>
163
- </template>
164
-
165
- <style lang="scss" scoped>
166
- .translation {
167
- ::v-deep(.el-dropdown-menu__item) {
168
- padding: 5px 40px;
169
- }
170
-
171
- .check-zh {
172
- position: absolute;
173
- left: 20px;
174
- }
175
-
176
- .check-en {
177
- position: absolute;
178
- left: 20px;
179
- }
180
- }
181
-
182
- .logout {
183
- max-width: 120px;
184
-
185
- ::v-deep(.el-dropdown-menu__item) {
186
- display: inline-flex;
187
- flex-wrap: wrap;
188
- min-width: 100%;
189
- }
190
- }
191
- </style>
1
+ <script setup lang="ts">
2
+ import { ref, nextTick } from 'vue';
3
+ import { storageLocal } from '@utogether/utils';
4
+ import { useNav } from '../../hooks/useNav';
5
+ import OrgSelect from '../lay-select-org/index.vue';
6
+ import Search from '../lay-search/index.vue';
7
+ // import Notice from '../lay-notice/index.vue';
8
+ import SidebarItem from './sidebarItem.vue';
9
+ import avatars from '../../../assets/images/avatars.jpg';
10
+ import { kSYSCONFIG } from '../../../contant';
11
+ import { useTranslationLang } from '../../hooks/useTranslationLang';
12
+ import globalization from '../../../assets/svg/globalization.svg?component';
13
+
14
+ import utogether from '../../../assets/images/utogether.png';
15
+ import { usePermissionStoreHook } from '../../../store/modules/permission';
16
+
17
+ const menuRef = ref();
18
+ const { route, locale, translationCh, translationEn } = useTranslationLang(menuRef);
19
+ const routeStore = usePermissionStoreHook();
20
+
21
+ const sysConfig = storageLocal.getItem(kSYSCONFIG) || {};
22
+
23
+ const logo = ref(sysConfig['logo'] || utogether);
24
+
25
+ const {
26
+ title,
27
+ logout,
28
+ backHome,
29
+ onPanel,
30
+ userInfo,
31
+ avatarsStyle,
32
+ getDropdownItemStyle,
33
+ getDropdownItemClass,
34
+ passwordItems
35
+ } = useNav();
36
+
37
+ const record: IRecord = {};
38
+
39
+ const refScrollbar = ref(null);
40
+ const showModal = ref(false);
41
+
42
+ nextTick(() => {
43
+ menuRef.value?.handleResize();
44
+ });
45
+
46
+ /**
47
+ * @description: 重置密码
48
+ */
49
+ const handleResetPwd = (): void => {
50
+ record.id = userInfo['id'];
51
+ showModal.value = true;
52
+ };
53
+
54
+ const handleScroll = e => {
55
+ const wheelDelta = e.wheelDelta || -e.deltaY * 40;
56
+ const scrollbar = refScrollbar.value;
57
+ // scrollbar.wrap$获取到包裹容器的element对象
58
+ scrollbar.setScrollLeft(scrollbar.wrapRef.scrollLeft + wheelDelta);
59
+ };
60
+ </script>
61
+ <script lang="ts">
62
+ export default { name: 'LayoutHorizontal' };
63
+ </script>
64
+ <template>
65
+ <div v-spinning="usePermissionStoreHook().wholeMenus.length === 0" class="horizontal-header">
66
+ <div class="flex flex-1 horizontal-header-left" @click="backHome">
67
+ <img :src="logo" class="h-full" />
68
+ <span class="text-xl u-project-text">{{ title }}</span>
69
+ </div>
70
+ <el-scrollbar ref="refScrollbar" class="flex-[3]" @wheel.prevent="handleScroll">
71
+ <template #default>
72
+ <el-menu
73
+ :default-active="route.path"
74
+ :ellipsis="false"
75
+ unique-opened
76
+ router
77
+ popper-class="udp-scrollbar"
78
+ class="horizontal-header-menu"
79
+ mode="horizontal"
80
+ >
81
+ <sidebar-item
82
+ v-for="route in routeStore.wholeMenus"
83
+ :key="route.path"
84
+ :item="route"
85
+ :base-path="route.path"
86
+ />
87
+ </el-menu>
88
+ </template>
89
+ </el-scrollbar>
90
+ <div class="horizontal-header-right flex-[2]">
91
+ <!-- 业务单元选择 -->
92
+ <OrgSelect v-if="sysConfig['orgTaggle'] === 'Y'" class="udp-horizontal" />
93
+ <!-- 菜单搜索 -->
94
+ <Search />
95
+ <!-- 通知 -->
96
+ <!-- <Notice id="header-notice" /> -->
97
+ <!-- 国际化 -->
98
+ <el-dropdown id="header-translation" class="px-2" trigger="click">
99
+ <globalization class="navbar-bg-hover w-[40px] h-[48px] p-[11px] cursor-pointer outline-hidden" />
100
+ <template #dropdown>
101
+ <el-dropdown-menu class="translation">
102
+ <el-dropdown-item
103
+ :style="getDropdownItemStyle(locale, 'zh')"
104
+ :class="['dark:text-white!', getDropdownItemClass(locale, 'zh')]"
105
+ @click="translationCh"
106
+ >
107
+ <span v-show="locale === 'zh'" class="check-zh">
108
+ <IconifyIconOffline icon="check" />
109
+ </span>
110
+ 简体中文
111
+ </el-dropdown-item>
112
+ <el-dropdown-item
113
+ :style="getDropdownItemStyle(locale, 'en')"
114
+ :class="['dark:text-white!', getDropdownItemClass(locale, 'en')]"
115
+ @click="translationEn"
116
+ >
117
+ <span v-show="locale === 'en'" class="check-en">
118
+ <IconifyIconOffline icon="check" />
119
+ </span>
120
+ English
121
+ </el-dropdown-item>
122
+ </el-dropdown-menu>
123
+ </template>
124
+ </el-dropdown>
125
+ <!-- 退出登录 -->
126
+ <el-dropdown trigger="click">
127
+ <span class="el-dropdown-link navbar-bg-hover">
128
+ <img v-if="avatars" :src="avatars" :style="avatarsStyle" />
129
+ <p class="dark:text-white">{{ userInfo.name }}</p>
130
+ </span>
131
+ <template #dropdown>
132
+ <el-dropdown-menu class="user-dropdown">
133
+ <el-dropdown-item @click="handleResetPwd">
134
+ <IconifyIconOffline icon="edit" />
135
+ {{ $t('message.udp.passwordReset') }}</el-dropdown-item
136
+ >
137
+ <el-divider style="margin: 3px 0 !important" />
138
+ <el-dropdown-item @click="logout">
139
+ <IconifyIconOffline icon="switch-button" />
140
+ {{ $t('message.udp.logout') }}
141
+ </el-dropdown-item>
142
+ </el-dropdown-menu>
143
+ </template>
144
+ </el-dropdown>
145
+ <span class="el-icon-setting navbar-bg-hover" @click="onPanel">
146
+ <IconifyIconOffline icon="ri:settings-5-fill" />
147
+ </span>
148
+ </div>
149
+ <ut-modal-form
150
+ v-if="showModal"
151
+ :record="record"
152
+ :items="passwordItems()"
153
+ :width="360"
154
+ :height="240"
155
+ :title="$t('message.udp.passwordReset')"
156
+ data-status="update"
157
+ url="/user/updatePwd"
158
+ method="put"
159
+ @close="showModal = false"
160
+ />
161
+ </div>
162
+ </template>
163
+
164
+ <style lang="scss" scoped>
165
+ .translation {
166
+ ::v-deep(.el-dropdown-menu__item) {
167
+ padding: 5px 40px;
168
+ }
169
+
170
+ .check-zh {
171
+ position: absolute;
172
+ left: 20px;
173
+ }
174
+
175
+ .check-en {
176
+ position: absolute;
177
+ left: 20px;
178
+ }
179
+ }
180
+
181
+ .logout {
182
+ max-width: 120px;
183
+
184
+ ::v-deep(.el-dropdown-menu__item) {
185
+ display: inline-flex;
186
+ flex-wrap: wrap;
187
+ min-width: 100%;
188
+ }
189
+ }
190
+ </style>