@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
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* @Author: wei.li
|
|
3
3
|
* @Date: 2022-03-02 17:07:59
|
|
4
4
|
* @LastEditors: levi7754 levi7754@163.com
|
|
5
|
-
* @LastEditTime: 2025-
|
|
5
|
+
* @LastEditTime: 2025-09-11 16:24:13
|
|
6
6
|
* @Description: SuForm
|
|
7
7
|
-->
|
|
8
8
|
|
|
@@ -16,23 +16,21 @@
|
|
|
16
16
|
:loading="loading"
|
|
17
17
|
:vertical="vertical"
|
|
18
18
|
:title-width="titleWidth"
|
|
19
|
-
|
|
19
|
+
title-overflow
|
|
20
20
|
title-align="right"
|
|
21
21
|
title-bold
|
|
22
22
|
v-bind="$attrs"
|
|
23
23
|
>
|
|
24
24
|
<template #dividerPrefix />
|
|
25
25
|
<template #collapseNode>
|
|
26
|
-
<
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
/>
|
|
35
|
-
</div>
|
|
26
|
+
<vxe-checkbox
|
|
27
|
+
v-model="collapseStatus"
|
|
28
|
+
content="查看更多"
|
|
29
|
+
:checked-value="false"
|
|
30
|
+
:unchecked-value="true"
|
|
31
|
+
class="pl-10"
|
|
32
|
+
@change="onChange"
|
|
33
|
+
/>
|
|
36
34
|
</template>
|
|
37
35
|
</vxe-form>
|
|
38
36
|
</div>
|
|
@@ -46,9 +44,8 @@ export default {
|
|
|
46
44
|
<script setup lang="ts">
|
|
47
45
|
import { useI18n } from 'vue-i18n';
|
|
48
46
|
import { ref, computed } from 'vue';
|
|
49
|
-
|
|
50
|
-
import {
|
|
51
|
-
// import type { IRecord, IFormItemProps } from '../../types';
|
|
47
|
+
import { formatRules, formatItems } from '@utogether/utils';
|
|
48
|
+
import { clone } from 'xe-utils';
|
|
52
49
|
|
|
53
50
|
export interface IProps {
|
|
54
51
|
record: IRecord; // 数据对象
|
|
@@ -84,7 +81,7 @@ const rules = computed(() => {
|
|
|
84
81
|
|
|
85
82
|
const formItems = computed(() => {
|
|
86
83
|
if (!props.items.length) return props.items;
|
|
87
|
-
return formatItems(props.items,
|
|
84
|
+
return formatItems(clone(props.items, true), props.dataStatus, 6);
|
|
88
85
|
});
|
|
89
86
|
|
|
90
87
|
const onChange = () => {
|
|
@@ -2,11 +2,11 @@
|
|
|
2
2
|
* @Author: wei.li
|
|
3
3
|
* @Date: 2021-11-17 16:33:37
|
|
4
4
|
* @LastEditors: levi7754 levi7754@163.com
|
|
5
|
-
* @LastEditTime: 2025-
|
|
5
|
+
* @LastEditTime: 2025-11-25 18:44:36
|
|
6
6
|
* @Description: file content
|
|
7
7
|
-->
|
|
8
8
|
<template>
|
|
9
|
-
<div style="width: 100%">
|
|
9
|
+
<div style="width: 100%; height: 100%">
|
|
10
10
|
<vxe-grid
|
|
11
11
|
ref="xgrid"
|
|
12
12
|
v-bind="data"
|
|
@@ -17,6 +17,7 @@
|
|
|
17
17
|
@cell-click="cellClick"
|
|
18
18
|
@cell-dblclick="cellDbclick"
|
|
19
19
|
@edit-activated="editEctivated"
|
|
20
|
+
@form-reset="onReset"
|
|
20
21
|
/>
|
|
21
22
|
<!-- <SearchScheme
|
|
22
23
|
v-if="showModal && props.url"
|
|
@@ -35,7 +36,9 @@ import { ref, onBeforeMount, reactive, getCurrentInstance, toRaw, useAttrs, onUn
|
|
|
35
36
|
import { VxeGridProps } from 'vxe-table';
|
|
36
37
|
import Sortable from 'sortablejs';
|
|
37
38
|
import { clone } from 'xe-utils';
|
|
38
|
-
import {
|
|
39
|
+
import { i18nColums, formatRules, errorMessage, dbstorage, warnMessage } from '@utogether/utils';
|
|
40
|
+
// import { http } from '../../../utils/udp/http';
|
|
41
|
+
import { formatGridItems } from '../../../utils/dataFormat';
|
|
39
42
|
import {
|
|
40
43
|
queryAll,
|
|
41
44
|
query,
|
|
@@ -46,9 +49,8 @@ import {
|
|
|
46
49
|
defaultColums,
|
|
47
50
|
onCheckMethod,
|
|
48
51
|
getAttrs
|
|
49
|
-
} from '
|
|
52
|
+
} from '../utils';
|
|
50
53
|
// import SearchScheme from '../components/SuSearch.vue';
|
|
51
|
-
// import type { IRecord, IFormItemProps, ITableColProps } from '../../types';
|
|
52
54
|
|
|
53
55
|
defineOptions({
|
|
54
56
|
name: 'UtGrid'
|
|
@@ -59,7 +61,7 @@ export interface IProps {
|
|
|
59
61
|
serviceCode?: IRecord;
|
|
60
62
|
defaultValue?: IRecord;
|
|
61
63
|
defaultParams?: IRecord;
|
|
62
|
-
url?: string;
|
|
64
|
+
url?: string | IRecord;
|
|
63
65
|
columns: Array<ITableColProps>;
|
|
64
66
|
items?: Array<IFormItemProps>;
|
|
65
67
|
editable?: boolean;
|
|
@@ -142,7 +144,7 @@ const getColumns = () => {
|
|
|
142
144
|
}
|
|
143
145
|
const act_columns = attrs.gridId ? formatColums(columns) : columns;
|
|
144
146
|
|
|
145
|
-
return i18nColums(act_columns);
|
|
147
|
+
return i18nColums(act_columns, attrs.sortable);
|
|
146
148
|
};
|
|
147
149
|
|
|
148
150
|
dbstorage.getItem(kSTORECOLUM).then(value => {
|
|
@@ -159,7 +161,7 @@ const data = reactive<VxeGridProps>({
|
|
|
159
161
|
columnConfig: { useKey: true },
|
|
160
162
|
toolbarConfig: { enabled: false },
|
|
161
163
|
sortConfig: { multiple: true, trigger: 'cell' },
|
|
162
|
-
height: $mode ? undefined : window.innerHeight -
|
|
164
|
+
height: $mode ? undefined : window.innerHeight - 92,
|
|
163
165
|
|
|
164
166
|
checkboxConfig: {
|
|
165
167
|
checkMethod: ({ row }) => onCheckMethod(row, props),
|
|
@@ -170,19 +172,22 @@ const data = reactive<VxeGridProps>({
|
|
|
170
172
|
proxyConfig: {
|
|
171
173
|
form: true, // 查询是需要启用表单代理
|
|
172
174
|
autoLoad: props.autoLoad,
|
|
175
|
+
showResponseMsgvxe: false,
|
|
176
|
+
showActionMsgvxe: false,
|
|
173
177
|
// 接收 Promise
|
|
174
178
|
ajax: {
|
|
175
179
|
queryAll: ({ form }) => queryAll(props, serviceApi, form),
|
|
176
|
-
query: ({ page, form }) =>
|
|
180
|
+
query: ({ page, form, code }) => {
|
|
181
|
+
return query(props, form, page, serviceApi, code, $mode);
|
|
182
|
+
},
|
|
177
183
|
delete: ({ body: { removeRecords } }) => del(serviceApi, removeRecords, props),
|
|
178
184
|
save: ({ body }) => Promise.all(save(serviceApi, body, props)),
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
saveError: response => callback('saveError', response)
|
|
185
|
+
querySuccess: ({ response }) => callback('querySuccess', response),
|
|
186
|
+
queryError: ({ response }) => callback('queryError', response),
|
|
187
|
+
deleteSuccess: ({ response }) => callback('deleteSuccess', response),
|
|
188
|
+
deleteError: ({ response }) => callback('deleteError', response),
|
|
189
|
+
saveSuccess: ({ response }) => callback('saveSuccess', response),
|
|
190
|
+
saveError: ({ response }) => callback('saveError', response)
|
|
186
191
|
}
|
|
187
192
|
},
|
|
188
193
|
columns: !attrs.gridId ? getColumns() : [],
|
|
@@ -316,6 +321,27 @@ const callback = (cb, response) => {
|
|
|
316
321
|
attrs?.callback && attrs?.callback[cb] && attrs?.callback[cb](response);
|
|
317
322
|
};
|
|
318
323
|
|
|
324
|
+
const onReset = async e => {
|
|
325
|
+
console.log(e);
|
|
326
|
+
const data = e.data;
|
|
327
|
+
const items = props.items.filter(f => f.itemRender?.props?.multiple);
|
|
328
|
+
console.log(items);
|
|
329
|
+
items.forEach(item => {
|
|
330
|
+
if (item.itemRender.props.defaultValue) {
|
|
331
|
+
data[`_${item.field}`] = item.itemRender.props.defaultValue.split(',');
|
|
332
|
+
data[`${item.field}`] = item.itemRender.props.defaultValue;
|
|
333
|
+
} else {
|
|
334
|
+
data[`_${item.field}`] = [];
|
|
335
|
+
}
|
|
336
|
+
});
|
|
337
|
+
if (items.length) {
|
|
338
|
+
// 多选时,重新查询一次
|
|
339
|
+
setTimeout(() => {
|
|
340
|
+
refreshData();
|
|
341
|
+
}, 200);
|
|
342
|
+
}
|
|
343
|
+
};
|
|
344
|
+
|
|
319
345
|
let sortable2: any;
|
|
320
346
|
const columnDrop = () => {
|
|
321
347
|
const $grid = xgrid.value;
|
|
@@ -389,11 +415,15 @@ const columnDrop = () => {
|
|
|
389
415
|
* @description 常用查询面板确认查询
|
|
390
416
|
* @param data 常用查询条件
|
|
391
417
|
*/
|
|
392
|
-
const onSearch = data => {
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
418
|
+
// const onSearch = data => {
|
|
419
|
+
// showModal.value = false;
|
|
420
|
+
// const { form } = xgrid.value.getProxyInfo();
|
|
421
|
+
// Object.assign(form, data);
|
|
422
|
+
// refreshData();
|
|
423
|
+
// };
|
|
424
|
+
|
|
425
|
+
const reloadGrid = () => {
|
|
426
|
+
setGridConfig();
|
|
397
427
|
};
|
|
398
428
|
|
|
399
429
|
/**
|
|
@@ -406,7 +436,8 @@ defineExpose({
|
|
|
406
436
|
refreshColumn,
|
|
407
437
|
getInstance,
|
|
408
438
|
showLoading,
|
|
409
|
-
hiddenLoading
|
|
439
|
+
hiddenLoading,
|
|
440
|
+
reloadGrid
|
|
410
441
|
});
|
|
411
442
|
|
|
412
443
|
const toolbarButtonClick = ({ code }) => {
|
|
@@ -428,13 +459,11 @@ const editEctivated = e => {
|
|
|
428
459
|
const addResizeListener = () => {
|
|
429
460
|
window.onresize = () => {
|
|
430
461
|
return (() => {
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
if (attrs?.mode === 'form' && !attrs?.height) {
|
|
462
|
+
let height = attrs?.height || window.innerHeight - 90;
|
|
463
|
+
if (attrs.mode !== 'inline' && !attrs?.height) {
|
|
434
464
|
height = window.innerHeight - 180;
|
|
435
465
|
}
|
|
436
466
|
data.height = height < 240 ? 240 : height;
|
|
437
|
-
console.log(data.height);
|
|
438
467
|
})();
|
|
439
468
|
};
|
|
440
469
|
};
|
|
@@ -446,7 +475,6 @@ nextTick(() => {
|
|
|
446
475
|
columnDrop();
|
|
447
476
|
}, 500);
|
|
448
477
|
});
|
|
449
|
-
|
|
450
478
|
/**
|
|
451
479
|
* @description Vue实例卸载
|
|
452
480
|
*/
|
|
@@ -488,6 +516,7 @@ const emit = defineEmits<{
|
|
|
488
516
|
}
|
|
489
517
|
}
|
|
490
518
|
}
|
|
519
|
+
|
|
491
520
|
.vxe-grid--layout-body-content-wrapper {
|
|
492
521
|
overflow: hidden;
|
|
493
522
|
}
|
|
@@ -1,10 +1,5 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import UtModalGrid2 from './modal-grid.vue';
|
|
5
|
-
import UtGrid2 from './grid.vue';
|
|
6
|
-
import UtForm2 from './form.vue';
|
|
7
|
-
import UtUpload2 from './upload.vue';
|
|
8
|
-
// import UtCountdown2 from './flip-down/FlipClock/flip-clock.vue';
|
|
1
|
+
import UtGrid2 from './grid/index.vue';
|
|
2
|
+
import UtForm2 from './form/form.vue';
|
|
3
|
+
import UtContent2 from './content/index.vue';
|
|
9
4
|
|
|
10
|
-
export { UtGrid2,
|
|
5
|
+
export { UtGrid2, UtForm2, UtContent2 };
|
|
@@ -0,0 +1,271 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div
|
|
3
|
+
class="first-ring"
|
|
4
|
+
v-bind="getBindValue"
|
|
5
|
+
:class="getStampBadgeClass"
|
|
6
|
+
style="position: absolute"
|
|
7
|
+
:style="{ transform: `rotate(${rotate}deg)`, top: `${top}px`, right: `${right}px` }"
|
|
8
|
+
>
|
|
9
|
+
<div class="second-ring" :class="getStampBadgeClass">
|
|
10
|
+
<div class="third-ring" :class="getStampBadgeClass">
|
|
11
|
+
<div class="forth-ring" :class="getStampBadgeClass">
|
|
12
|
+
<div class="content-rectangle ellipsis" :class="getStampBadgeClass">
|
|
13
|
+
<span class="">{{ getContent(content) }}</span>
|
|
14
|
+
</div>
|
|
15
|
+
</div>
|
|
16
|
+
</div>
|
|
17
|
+
</div>
|
|
18
|
+
</div>
|
|
19
|
+
</template>
|
|
20
|
+
|
|
21
|
+
<script>
|
|
22
|
+
import { storageLocal } from '@utogether/utils';
|
|
23
|
+
export default {
|
|
24
|
+
name: 'UTStampBadge',
|
|
25
|
+
props: {
|
|
26
|
+
color: {
|
|
27
|
+
type: String,
|
|
28
|
+
default: 'primary',
|
|
29
|
+
validator: v => ['primary', 'error', 'warning', 'success', 'info'].includes(v)
|
|
30
|
+
},
|
|
31
|
+
/**
|
|
32
|
+
* stamp badge size.
|
|
33
|
+
* @default: middle
|
|
34
|
+
*/
|
|
35
|
+
size: {
|
|
36
|
+
type: String,
|
|
37
|
+
default: 'large',
|
|
38
|
+
validator: v => ['large', 'middle', 'small'].includes(v)
|
|
39
|
+
},
|
|
40
|
+
/**
|
|
41
|
+
* stamp badge rotate deg.
|
|
42
|
+
* @default: 0
|
|
43
|
+
*/
|
|
44
|
+
rotate: { type: Number, default: 45 },
|
|
45
|
+
top: { type: Number, default: 60 },
|
|
46
|
+
right: { type: Number, default: 40 },
|
|
47
|
+
content: { type: String, default: 'Unknown' },
|
|
48
|
+
code: { type: String, default: '' }
|
|
49
|
+
},
|
|
50
|
+
computed: {
|
|
51
|
+
getStampBadgeClass() {
|
|
52
|
+
const { color, size } = this.$props;
|
|
53
|
+
return [
|
|
54
|
+
{
|
|
55
|
+
[`stamp-badge-${color}`]: !!color,
|
|
56
|
+
[`stamp-badge-${size}`]: !!size
|
|
57
|
+
}
|
|
58
|
+
];
|
|
59
|
+
},
|
|
60
|
+
getBindValue() {
|
|
61
|
+
return { ...this.$attrs, ...this.$props };
|
|
62
|
+
}
|
|
63
|
+
},
|
|
64
|
+
methods: {
|
|
65
|
+
getContent(content) {
|
|
66
|
+
if (!content) return content;
|
|
67
|
+
if (this.code) {
|
|
68
|
+
const dict = storageLocal.getItem('kLov')[this.code];
|
|
69
|
+
const data = dict.children.find(f => f.dictCode === this.content);
|
|
70
|
+
return data ? data.dictName : content;
|
|
71
|
+
}
|
|
72
|
+
return content;
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
};
|
|
76
|
+
</script>
|
|
77
|
+
|
|
78
|
+
<style lang="scss" scoped>
|
|
79
|
+
.first-ring {
|
|
80
|
+
z-index: 999;
|
|
81
|
+
display: flex;
|
|
82
|
+
align-items: center;
|
|
83
|
+
justify-content: center;
|
|
84
|
+
border-radius: 100px;
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
.second-ring {
|
|
88
|
+
display: flex;
|
|
89
|
+
align-items: center;
|
|
90
|
+
justify-content: center;
|
|
91
|
+
background: #fff;
|
|
92
|
+
border-radius: 100px;
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
.third-ring {
|
|
96
|
+
display: flex;
|
|
97
|
+
align-items: center;
|
|
98
|
+
justify-content: center;
|
|
99
|
+
border-radius: 100px;
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
.forth-ring {
|
|
103
|
+
position: relative;
|
|
104
|
+
display: flex;
|
|
105
|
+
align-items: center;
|
|
106
|
+
justify-content: center;
|
|
107
|
+
background: #fff;
|
|
108
|
+
border-radius: 100px;
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
.content-rectangle {
|
|
112
|
+
position: absolute;
|
|
113
|
+
font-weight: bold;
|
|
114
|
+
text-align: center;
|
|
115
|
+
background: #fff;
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
.ellipsis {
|
|
119
|
+
overflow: hidden;
|
|
120
|
+
text-overflow: ellipsis;
|
|
121
|
+
white-space: nowrap;
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
// primary
|
|
125
|
+
.stamp-badge-primary.first-ring {
|
|
126
|
+
background: #1890ff;
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
.stamp-badge-primary.third-ring {
|
|
130
|
+
background: #1890ff;
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
.stamp-badge-primary.content-rectangle {
|
|
134
|
+
color: #1890ff;
|
|
135
|
+
border: 1px solid #1890ff;
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
// success
|
|
139
|
+
.stamp-badge-success.first-ring {
|
|
140
|
+
background: #52c41a;
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
.stamp-badge-success.third-ring {
|
|
144
|
+
background: #52c41a;
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
.stamp-badge-success.content-rectangle {
|
|
148
|
+
color: #52c41a;
|
|
149
|
+
border: 1px solid #52c41a;
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
// error
|
|
153
|
+
.stamp-badge-error.first-ring {
|
|
154
|
+
background: #ff4d4f;
|
|
155
|
+
}
|
|
156
|
+
|
|
157
|
+
.stamp-badge-error.third-ring {
|
|
158
|
+
background: #ff4d4f;
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
.stamp-badge-error.content-rectangle {
|
|
162
|
+
color: #ff4d4f;
|
|
163
|
+
border: 1px solid #ff4d4f;
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
// warning
|
|
167
|
+
.stamp-badge-warning.first-ring {
|
|
168
|
+
background: #faad14;
|
|
169
|
+
}
|
|
170
|
+
|
|
171
|
+
.stamp-badge-warning.third-ring {
|
|
172
|
+
background: #faad14;
|
|
173
|
+
}
|
|
174
|
+
|
|
175
|
+
.stamp-badge-warning.content-rectangle {
|
|
176
|
+
color: #faad14;
|
|
177
|
+
border: 1px solid #faad14;
|
|
178
|
+
}
|
|
179
|
+
|
|
180
|
+
// info
|
|
181
|
+
.stamp-badge-info.first-ring {
|
|
182
|
+
background: #ccc;
|
|
183
|
+
}
|
|
184
|
+
|
|
185
|
+
.stamp-badge-info.third-ring {
|
|
186
|
+
background: #ccc;
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
.stamp-badge-info.content-rectangle {
|
|
190
|
+
color: #ccc;
|
|
191
|
+
border: 1px solid #ccc;
|
|
192
|
+
}
|
|
193
|
+
|
|
194
|
+
// large
|
|
195
|
+
.stamp-badge-large.first-ring {
|
|
196
|
+
width: 84px;
|
|
197
|
+
height: 84px;
|
|
198
|
+
}
|
|
199
|
+
|
|
200
|
+
.stamp-badge-large.second-ring {
|
|
201
|
+
width: 80px;
|
|
202
|
+
height: 80px;
|
|
203
|
+
}
|
|
204
|
+
|
|
205
|
+
.stamp-badge-large.third-ring {
|
|
206
|
+
width: 74px;
|
|
207
|
+
height: 74px;
|
|
208
|
+
}
|
|
209
|
+
|
|
210
|
+
.stamp-badge-large.forth-ring {
|
|
211
|
+
width: 64px;
|
|
212
|
+
height: 64px;
|
|
213
|
+
}
|
|
214
|
+
|
|
215
|
+
.stamp-badge-large.content-rectangle {
|
|
216
|
+
width: 90px;
|
|
217
|
+
font-size: 1.2rem;
|
|
218
|
+
}
|
|
219
|
+
|
|
220
|
+
// middle
|
|
221
|
+
.stamp-badge-middle.first-ring {
|
|
222
|
+
width: 64px;
|
|
223
|
+
height: 64px;
|
|
224
|
+
}
|
|
225
|
+
|
|
226
|
+
.stamp-badge-middle.second-ring {
|
|
227
|
+
width: 60px;
|
|
228
|
+
height: 60px;
|
|
229
|
+
}
|
|
230
|
+
|
|
231
|
+
.stamp-badge-middle.third-ring {
|
|
232
|
+
width: 56px;
|
|
233
|
+
height: 56px;
|
|
234
|
+
}
|
|
235
|
+
|
|
236
|
+
.stamp-badge-middle.forth-ring {
|
|
237
|
+
width: 48px;
|
|
238
|
+
height: 48px;
|
|
239
|
+
}
|
|
240
|
+
|
|
241
|
+
.stamp-badge-middle.content-rectangle {
|
|
242
|
+
width: 70px;
|
|
243
|
+
font-size: 1rem;
|
|
244
|
+
}
|
|
245
|
+
|
|
246
|
+
// small
|
|
247
|
+
.stamp-badge-small.first-ring {
|
|
248
|
+
width: 54px;
|
|
249
|
+
height: 54px;
|
|
250
|
+
}
|
|
251
|
+
|
|
252
|
+
.stamp-badge-small.second-ring {
|
|
253
|
+
width: 50px;
|
|
254
|
+
height: 50px;
|
|
255
|
+
}
|
|
256
|
+
|
|
257
|
+
.stamp-badge-small.third-ring {
|
|
258
|
+
width: 46px;
|
|
259
|
+
height: 46px;
|
|
260
|
+
}
|
|
261
|
+
|
|
262
|
+
.stamp-badge-small.forth-ring {
|
|
263
|
+
width: 38px;
|
|
264
|
+
height: 38px;
|
|
265
|
+
}
|
|
266
|
+
|
|
267
|
+
.stamp-badge-small.content-rectangle {
|
|
268
|
+
width: 60px;
|
|
269
|
+
font-size: 0.8rem;
|
|
270
|
+
}
|
|
271
|
+
</style>
|