kso-sel-org 1.0.4 → 1.0.6
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/components/Dialog/hooks/load.d.ts +17 -0
- package/dist/components/Dialog/index.d.ts +2 -0
- package/dist/components/Lstab/hooks/load.d.ts +28 -0
- package/dist/components/Lstab/hooks/methods.d.ts +5 -0
- package/dist/components/MenuAuthor/index.d.ts +1 -0
- package/dist/components/OperAuthor/index.d.ts +1 -0
- package/dist/components/RoleAssign/index.d.ts +1 -0
- package/dist/components/RoleAuthor/index.d.ts +1 -0
- package/dist/components/Selector/index.d.ts +3 -0
- package/dist/components/Selector/src/org-selector/index.vue.d.ts +132 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.umd.js +2 -1
- package/package.json +5 -3
- /package/dist/{style.css → index.css} +0 -0
@@ -0,0 +1,17 @@
|
|
1
|
+
export declare const load: () => {
|
2
|
+
dialog: any;
|
3
|
+
columns: any;
|
4
|
+
queryCondis: any;
|
5
|
+
pagination: any;
|
6
|
+
tableData: any;
|
7
|
+
load_dialog_config: () => Promise<void>;
|
8
|
+
page_current_change: () => void;
|
9
|
+
sort_change: ({ prop, order }: {
|
10
|
+
prop: any;
|
11
|
+
order: any;
|
12
|
+
}) => void;
|
13
|
+
load_table_data: (pageNum?: number) => void;
|
14
|
+
sort_header_cell_class: ({ column }: {
|
15
|
+
column: any;
|
16
|
+
}) => string;
|
17
|
+
};
|
@@ -0,0 +1,28 @@
|
|
1
|
+
export declare const load: () => {
|
2
|
+
load_grid_config: () => Promise<void>;
|
3
|
+
load_table_data: (pageNum?: number) => void;
|
4
|
+
filter_change: (filters: any) => void;
|
5
|
+
sort_header_cell_class: ({ column }: {
|
6
|
+
column: any;
|
7
|
+
}) => string;
|
8
|
+
sort_change: ({ prop, order }: {
|
9
|
+
prop: any;
|
10
|
+
order: any;
|
11
|
+
}) => void;
|
12
|
+
page_size_change: () => void;
|
13
|
+
page_current_change: () => void;
|
14
|
+
clearRowFilter: () => void;
|
15
|
+
lstabRef: any;
|
16
|
+
cfgLoading: any;
|
17
|
+
queryCondis: any;
|
18
|
+
columns: any;
|
19
|
+
loading: any;
|
20
|
+
lstab: any;
|
21
|
+
headFuncOper: any;
|
22
|
+
rowFuncOper: any;
|
23
|
+
headFuncOperBatch: any;
|
24
|
+
rowFuncOperBatch: any;
|
25
|
+
quickFilter: any;
|
26
|
+
pagination: any;
|
27
|
+
tableData: any;
|
28
|
+
};
|
@@ -0,0 +1 @@
|
|
1
|
+
export { default as kuMenuAuthor } from './src/index.vue';
|
@@ -0,0 +1 @@
|
|
1
|
+
export { default as kuOperAuthor } from './src/index.vue';
|
@@ -0,0 +1 @@
|
|
1
|
+
export { default as kuRoleAssign } from './src/index.vue';
|
@@ -0,0 +1 @@
|
|
1
|
+
export { default as kuRoleAuthor } from './src/index.vue';
|
@@ -0,0 +1,132 @@
|
|
1
|
+
declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
|
2
|
+
/** 默认选中code值 */
|
3
|
+
modelValue: string;
|
4
|
+
/** 根机构ID(根机构ID,如果不设置,则返回所有机构树,传入则只显示该机构下的所有单位树) */
|
5
|
+
rootOrgId?: string | undefined;
|
6
|
+
/** 单位类型(如果不设置,则返回所有单位类型,否则传值(01:隶属局单位,02:直属局单位,03:总署单位))*/
|
7
|
+
orgType?: string | undefined;
|
8
|
+
/** 文本框显示内容 */
|
9
|
+
inputText?: string | undefined;
|
10
|
+
/** 返回内容处理 */
|
11
|
+
returnValue?: string | undefined;
|
12
|
+
/** 是否只读 */
|
13
|
+
readonly?: boolean | undefined;
|
14
|
+
/** 是否清除 */
|
15
|
+
isClear?: boolean | undefined;
|
16
|
+
/** 是否禁用 */
|
17
|
+
disabled?: boolean | undefined;
|
18
|
+
/** 按钮文本内容 */
|
19
|
+
buttonText?: string | undefined;
|
20
|
+
/** 开启复选 */
|
21
|
+
multiple?: boolean | undefined;
|
22
|
+
/** 事件绑定 */
|
23
|
+
bindEvent?: boolean | undefined;
|
24
|
+
/** 根据传进来的code查对应的name,覆盖inputText值 */
|
25
|
+
defaultText?: boolean | undefined;
|
26
|
+
/** 扩展查询参数 */
|
27
|
+
reqParams?: object | undefined;
|
28
|
+
}>, {
|
29
|
+
modelValue: string;
|
30
|
+
rootOrgId: string;
|
31
|
+
orgType: string;
|
32
|
+
inputText: string;
|
33
|
+
returnValue: string;
|
34
|
+
readonly: boolean;
|
35
|
+
isClear: boolean;
|
36
|
+
disabled: boolean;
|
37
|
+
buttonText: string;
|
38
|
+
multiple: boolean;
|
39
|
+
bindEvent: boolean;
|
40
|
+
defaultText: boolean;
|
41
|
+
reqParams: undefined;
|
42
|
+
}>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
43
|
+
onSelect: (...args: any[]) => void;
|
44
|
+
"update:modelValue": (...args: any[]) => void;
|
45
|
+
onCancel: (...args: any[]) => void;
|
46
|
+
onClear: (...args: any[]) => void;
|
47
|
+
}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
|
48
|
+
/** 默认选中code值 */
|
49
|
+
modelValue: string;
|
50
|
+
/** 根机构ID(根机构ID,如果不设置,则返回所有机构树,传入则只显示该机构下的所有单位树) */
|
51
|
+
rootOrgId?: string | undefined;
|
52
|
+
/** 单位类型(如果不设置,则返回所有单位类型,否则传值(01:隶属局单位,02:直属局单位,03:总署单位))*/
|
53
|
+
orgType?: string | undefined;
|
54
|
+
/** 文本框显示内容 */
|
55
|
+
inputText?: string | undefined;
|
56
|
+
/** 返回内容处理 */
|
57
|
+
returnValue?: string | undefined;
|
58
|
+
/** 是否只读 */
|
59
|
+
readonly?: boolean | undefined;
|
60
|
+
/** 是否清除 */
|
61
|
+
isClear?: boolean | undefined;
|
62
|
+
/** 是否禁用 */
|
63
|
+
disabled?: boolean | undefined;
|
64
|
+
/** 按钮文本内容 */
|
65
|
+
buttonText?: string | undefined;
|
66
|
+
/** 开启复选 */
|
67
|
+
multiple?: boolean | undefined;
|
68
|
+
/** 事件绑定 */
|
69
|
+
bindEvent?: boolean | undefined;
|
70
|
+
/** 根据传进来的code查对应的name,覆盖inputText值 */
|
71
|
+
defaultText?: boolean | undefined;
|
72
|
+
/** 扩展查询参数 */
|
73
|
+
reqParams?: object | undefined;
|
74
|
+
}>, {
|
75
|
+
modelValue: string;
|
76
|
+
rootOrgId: string;
|
77
|
+
orgType: string;
|
78
|
+
inputText: string;
|
79
|
+
returnValue: string;
|
80
|
+
readonly: boolean;
|
81
|
+
isClear: boolean;
|
82
|
+
disabled: boolean;
|
83
|
+
buttonText: string;
|
84
|
+
multiple: boolean;
|
85
|
+
bindEvent: boolean;
|
86
|
+
defaultText: boolean;
|
87
|
+
reqParams: undefined;
|
88
|
+
}>>> & {
|
89
|
+
onOnSelect?: ((...args: any[]) => any) | undefined;
|
90
|
+
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
91
|
+
onOnCancel?: ((...args: any[]) => any) | undefined;
|
92
|
+
onOnClear?: ((...args: any[]) => any) | undefined;
|
93
|
+
}, {
|
94
|
+
modelValue: string;
|
95
|
+
multiple: boolean;
|
96
|
+
readonly: boolean;
|
97
|
+
disabled: boolean;
|
98
|
+
bindEvent: boolean;
|
99
|
+
inputText: string;
|
100
|
+
returnValue: string;
|
101
|
+
isClear: boolean;
|
102
|
+
buttonText: string;
|
103
|
+
defaultText: boolean;
|
104
|
+
reqParams: object;
|
105
|
+
rootOrgId: string;
|
106
|
+
orgType: string;
|
107
|
+
}, {}>, {
|
108
|
+
func?(_: {}): any;
|
109
|
+
}>;
|
110
|
+
export default _default;
|
111
|
+
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
112
|
+
type __VLS_TypePropsToRuntimeProps<T> = {
|
113
|
+
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
114
|
+
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
115
|
+
} : {
|
116
|
+
type: import('vue').PropType<T[K]>;
|
117
|
+
required: true;
|
118
|
+
};
|
119
|
+
};
|
120
|
+
type __VLS_WithDefaults<P, D> = {
|
121
|
+
[K in keyof Pick<P, keyof P>]: K extends keyof D ? __VLS_Prettify<P[K] & {
|
122
|
+
default: D[K];
|
123
|
+
}> : P[K];
|
124
|
+
};
|
125
|
+
type __VLS_Prettify<T> = {
|
126
|
+
[K in keyof T]: T[K];
|
127
|
+
} & {};
|
128
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
129
|
+
new (): {
|
130
|
+
$slots: S;
|
131
|
+
};
|
132
|
+
};
|
package/dist/index.d.ts
ADDED
package/dist/index.umd.js
CHANGED
@@ -1 +1,2 @@
|
|
1
|
-
(function(e,
|
1
|
+
(function(e,b){typeof exports=="object"&&typeof module<"u"?module.exports=b(require("vue")):typeof define=="function"&&define.amd?define(["vue"],b):(e=typeof globalThis<"u"?globalThis:e||self,e["kso-sel-org"]=b(e.Vue))})(this,function(e){"use strict";var b=document.createElement("style");b.textContent=`.org-list-box[data-v-e2b739c9]{padding:10px;display:flex;justify-content:space-between;box-sizing:border-box}.org-list-box .left-tree-box[data-v-e2b739c9]{border:1px solid #ebeef5;width:50%;overflow:hidden}.org-list-box .left-tree-box .search-box[data-v-e2b739c9]{height:52px;padding:5px 12px;background:#f0f2f5;box-sizing:border-box;display:flex;align-items:center}.org-list-box .left-tree-box .search-box label[data-v-e2b739c9]{color:#303133;font-weight:700}.org-list-box .left-tree-box .search-box[data-v-e2b739c9] .el-input{width:calc(100% - 100px);margin-left:10px}.org-list-box .right-selected-list[data-v-e2b739c9]{border:1px solid #ebeef5;width:48%}.org-list-box .right-selected-list .selected-box[data-v-e2b739c9]{height:52px;padding:5px 12px;background:#f0f2f5;box-sizing:border-box;display:flex;align-items:center;justify-content:space-between}.org-list-box .right-selected-list .selected-box span[data-v-e2b739c9]{color:#303133;font-weight:700}.org-list-box .right-selected-list .selected-box .delete-btn[data-v-e2b739c9]{display:inline-block;width:17px;height:17px;background:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAARCAYAAAA7bUf6AAAAAXNSR0IArs4c6QAAAARzQklUCAgICHwIZIgAAADkSURBVDiN7ZOxccJAEEXfwiX2EFCCSnAHhkoM+V4NtKAZRCw6kVwCHUAHDixImPsOPJ5BMrKsGYd+4d79d/+CNTqc3SvBojv/wqB+LIrl7Sxc3FuBBPM+AYBg3s2EBNVPoTs8dTNBZmuTMmCD2V7wOmQxeEZamVme4GAAF/dFgkpm69l2ux+SvMe4MqmcwPKhKOrJyK/cpVfSuKuJsQRoYiwbd42W/EmTf8l3DGqkE4BSOhjUfXdD38Htks12uxzIRzcZQ6uJwebs/jIUktTa9E9JCEeu1zekTJD96nmzI9PpEeADOClObZiMikMAAAAASUVORK5CYII=) no-repeat;block-size:100% 100%}.org-list-box .right-selected-list[data-v-e2b739c9] .el-icon svg{width:1.5em;height:1.5em}.org-list-box .tree-content-box[data-v-e2b739c9]{height:420px;padding:5px 15px;box-sizing:border-box;overflow:auto}.org-list-box ul li[data-v-e2b739c9]{width:100%;line-height:40px;display:flex;align-items:center;justify-content:space-between;border:solid 1px #d7dde4;border-radius:4px;margin-bottom:8px;padding:0 20px;box-sizing:border-box}.org-list-box ul .org-name[data-v-e2b739c9]{width:92%;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.org-list-box ul[data-v-e2b739c9] .el-icon{cursor:pointer}.org-list-box .org-del .img-box[data-v-e2b739c9]{margin:7px 0 0;cursor:pointer}.org-list-box .flow-modal-title[data-v-e2b739c9]{height:40px;background:#2b5fda;width:100%;text-indent:1em;color:#fff;line-height:40px}.selector-footer[data-v-e2b739c9]{padding:10px;display:flex;justify-content:flex-end;border-top:solid 1px #dcdfe6}[data-v-e2b739c9] .tree-folder-node-icon{display:inline-block;width:18px;height:18px;background:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAAARzQklUCAgICHwIZIgAAAIvSURBVFiF7ZaxaxRBFMZ/73JFhBQWlhIDXmGRIoKFxR1OYboIFloKu7cBAyLEykpIYSFYi4W32QQFiwTyDwhOsaJgm+KKNFpdYRkkYJJncZO7SW7vdu+SgMH74Ir5bt77vn3v7czCGP87JG+DSfQtytIZajb5Q80+ll8ApdztZysOcIMJ7h4tykME7iCkI8sqFaAKgDA5vAEhtaGEo+qbWAPEGfCQ34JzRvEKKHOmobN2UbZ92sSaADBBagOJAcyaRhy0n9ZGg6s2TAXmKPHdrOqDY6wQIASoV16l2uFzMNCAeae3T1CTwIZJ9Hlh2zno2wLT0PsI7z1qG5gFQHllEp3hB09tXXrOEjeshQY2swIm1mWEDYQpR63zk5vAQ2DPmVhimi3zRqeychTFsQqYFS1zjdcoyx3ykBd2UV661aaJtYWwBVwBFrjEZ5PoPRtKy3uAKsJ1AFuX9UEGOhUwK1pmmo+e+D7wyBMHwEaSItSAHUfdQvlqGlrxskbAmvsNRLcFV1kAjiZ8F2He1uVDVpANpYlQQ/jmqBlKjDSYXQPCZY9/ZkOxgwJtKC1+M+/Fd9t5SIwSovmDmP0WKPt5gQD2ieyaVe3lI0mh2L1xMY5ik2iCtk+1rPf+NPsvRgWGhvIl/1vrHA3YujSARpG9/2gLhMjEeqez9q7azv1/Ekq173/tnJUsumtA2fP6Vs36fHKJgj4SlX4iPVB3oeG34IBPQLNQgtOh6bTGGAOAv4Uio5lixzLEAAAAAElFTkSuQmCC) no-repeat;background-size:100% 100%}[data-v-e2b739c9] .tree-file-node-icon{display:inline-block;width:18px;height:18px;background:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAAARzQklUCAgICHwIZIgAAAJxSURBVFiF7Za/a1NRFMc/5zWFCh07ZBBF6NDBoUOhFjpchw5iCwpdHARfWiEigotTl4CjiyBSi315gRa6VByiOEjoFYQ6dHToUBBbh/wBoS0YehzeTWh+vDRJ0xahXwiEc8893+89P+598D/DLOmQWdKh08TwuibP6iz97NHPnsnq7LkKMIGmUdaAAWAAZc0Emj4XASarCwiLCImqUUggLJqsLnQaT9omzmiC67xCee5MZeCJ+78ITpDwmt+8sBkp90yAyWiCa6wBlVqXAN+mZB1cP0AIDLr1dXZ50I6IEwWYtzrIFfKAqZIrd+ycfK/xC3QS4csxEZYDZuxTKXUtwISaRMkDY85URLhtfdmO8R9B2QCSzrSFMGN9KcZxxDahWdZhF6xCvo0wEUcOYH3ZRpgAKj5jKBtmWYfj9jTNgFnWm3h8rZ5E+AHcb3WSmv2hJoGPKLecqcgRU3Zeftb7NmTA1XKzSq4U2GeqXXIA60uRfaZQCs6URNg0gU7W+9ZkwHXzCtEFE2GX/nZHqh5uev4eMx0CDyvTUyPA3WRvai4YwKakeZmyOo1wFwDls03Jpxg/rTEoZeCZnZN34EpgQh3BYxyPVYQcsNPyZFl9CeRR0ihpIG8CzbTaA+wg5PBYxWPchDoCcU0YaojyCBozYN7rVTx+1WcKpcwRN+xj+VMnNsqAkLO++PVcnT9GfYw2kEcECfoY7TRc5wKU+GlotdYrAXZOtoBvTcgLbu1sBQBwwDRKQPQolVACDrnXTajGWrYB98DMu9+p0PUnWa9wKeDCBZzYhCbQ8EIFINGVfFZoXgLlA9GM9wolF/MSl2jAP+MZ1PXRPKaQAAAAAElFTkSuQmCC) no-repeat;background-size:100% 100%}[data-v-e2b739c9] .el-input{height:32px}[data-v-e2b739c9] .node-text-box{display:flex;align-items:center}[data-v-e2b739c9] .node-text-box .el-radio{margin-right:5px}[data-v-e2b739c9] .node-text-box .el-radio .el-radio__label{display:none}[data-v-e2b739c9] .el-tree--highlight-current .el-tree-node.is-current>.el-tree-node__content{background-color:#f0f5ff}[data-v-e2b739c9] .el-input__icon{color:#a8abb2}[data-v-e2b739c9] .el-input-group__append{position:relative}[data-v-e2b739c9] .el-input-group__append .el-icon{position:absolute;left:-24px;top:9px;z-index:2;cursor:pointer}[data-v-e2b739c9]::-webkit-scrollbar{width:5px}[data-v-e2b739c9]::-webkit-scrollbar-thumb{border-radius:3px;background:#b7c7dd}[data-v-e2b739c9]::-webkit-scrollbar-track{border-radius:3px;background:#ededed}
|
2
|
+
`,document.head.appendChild(b);const N=f=>(e.pushScopeId("data-v-e2b739c9"),f=f(),e.popScopeId(),f),v={class:"org-selector"},R={class:"org-list-box"},Z={class:"left-tree-box"},D={class:"search-box"},K=N(()=>e.createElementVNode("label",null,"单位列表",-1)),F={class:"tree-content-box"},z={class:"right-selected-list"},O=N(()=>e.createElementVNode("span",null,"已选单位",-1)),Q={class:"tree-content-box"},U=["title"],P={class:"org-name"},j={class:"selector-footer"},Y=e.defineComponent({__name:"index",props:{modelValue:{default:""},rootOrgId:{default:""},orgType:{default:""},inputText:{default:""},returnValue:{default:""},readonly:{type:Boolean,default:!0},isClear:{type:Boolean,default:!0},disabled:{type:Boolean,default:!1},buttonText:{default:"选择"},multiple:{type:Boolean,default:!0},bindEvent:{type:Boolean,default:!0},defaultText:{type:Boolean,default:!1},reqParams:{default:void 0}},emits:["onCancel","onSelect","update:modelValue","onClear"],setup(f,{emit:u}){const n=f;let m=e.useAttrs();const C=e.inject("req"),{warningMsgBox:q}=e.inject("msgBox"),G={children:"childrenList",label:"orgName"},d=e.ref(null);let c=e.ref(""),V=e.ref(!1),g=e.ref(!1),k=e.ref(!1),x=e.ref(""),h=e.ref(""),p=e.ref([]),y=e.ref([]),A=e.ref([]);e.watch(()=>n.modelValue,()=>{n.defaultText&&!k.value&&_()}),e.watch(()=>n.inputText,t=>{c.value=t});function E(){if(n.modelValue?A.value=n.modelValue.split(","):A.value=[],g.value=!0,V.value&&d.value){d.value.setCheckedKeys(A.value),p.value=d.value.getCheckedNodes();return}J()}function M(){n.bindEvent&&E()}function J(){let t={pid:n.rootOrgId,orgType:n.orgType};n.reqParams&&(t=Object.assign(t,n.reqParams)),C.post({url:getKsoRoot("/sys/org/list-by-condition"),params:t}).then(({data:o})=>{let l=X(o);l&&l.length>0&&l.forEach(a=>{a.expanded=!0}),y.value=l,d.value.setCheckedKeys(A.value),V.value=!0})}function _(){if(!n.modelValue)return;k.value=!0;let t={ids:n.modelValue};C.post({url:getKsoRoot("/sys/org/find-by-ids"),params:t}).then(({data:o})=>{if(o&&o.length>0){let l=[];o.forEach(a=>{l.push(a.orgName)}),c.value=l.join(",")}})}function X(t){return t.forEach(o=>{o.name=o.orgName,A.value.length>0&&A.value.includes(o.id)&&p.value.push(o);let l=[];t.forEach(a=>{a.pid==o.id&&l.push(a)}),o.childrenList=l}),t=t.filter(o=>o.pid==""),t}function L(t,{node:o,data:l}){l.expanded&&(o.expanded=!0);let a="tree-file-node-icon";o.childNodes&&o.childNodes.length>0&&(a="tree-folder-node-icon");let r=[];if(!n.multiple){let s="";l.id===x.value&&(s=l.id),r.push(t(e.resolveComponent("el-radio"),{modelValue:s,label:l.id,size:"large"}))}return r.push(t("i",{class:a,style:{marginRight:"5px"}})),r.push(t("span",{attrs:{title:l.name}},l.name)),t("span",{class:"node-text-box"},r)}function W(t,o){return t?o.name.indexOf(t)!==-1||o.id.indexOf(t)!==-1:!0}function H(){d.value.filter(h.value),h.value||$(y.value[0].id,!1)}function $(t,o){var l=d.value.store.nodesMap;for(let a in l)t===a?l[a].expanded=!0:l[a].expanded=o}function ee(t){n.multiple||(d.value.setCheckedNodes([t]),x.value=t.id),p.value=d.value.getCheckedNodes()}function te(t,o){p.value.splice(o,1),x.value="",d.value.setCheckedNodes(p.value)}function B(){p.value=[],x.value="",d.value&&d.value.setCheckedNodes(p.value)}function I(){g.value=!1,u("onCancel","")}function oe(){if(p.value.length==0)return q("请选择数据"),!1;let t=le(p.value);ae(t),g.value=!1,u("onSelect",t)}function le(t){let o=[];return t.forEach(l=>{let a={id:l.id,orgName:l.orgName,orgType:l.orgType,sname:l.sname,fname:l.fname,regId:l.regId,regName:l.regName,cityId:l.cityId,cityName:l.cityName};o.push(a)}),o}function ae(t){let o={};Object.keys(t[0]).forEach(a=>{o[a]=[]}),t.forEach(a=>{var r;for(let s in a)(r=o[s])==null||r.push(a[s])}),c.value=o.orgName.join(","),u("update:modelValue",o.id.join(","));let l=n.returnValue.split("|");l&&l.length>0&&l.forEach(a=>{let r=a.split(":");if(r&&r.length>1){let s=o[r[1]],w=s?s.join(","):"";m.sync[r[0]]=w}})}function S(){if(c.value="",u("update:modelValue",""),n.returnValue){let t=n.returnValue.split("|");t&&t.length>0&&t.forEach(o=>{let l=o.split(":");l&&l.length>1&&(m.sync[l[0]]="")})}B(),u("onClear","")}return e.onMounted(()=>{n.defaultText&&!k.value?_():c.value=n.inputText,n.multiple||(x.value=n.modelValue)}),(t,o)=>{const l=e.resolveComponent("CircleClose"),a=e.resolveComponent("el-icon"),r=e.resolveComponent("el-button"),s=e.resolveComponent("el-input"),w=e.resolveComponent("el-tree"),ne=e.resolveComponent("CircleCloseFilled"),re=e.resolveComponent("el-dialog");return e.openBlock(),e.createElementBlock("div",v,[t.$slots.func?(e.openBlock(),e.createElementBlock("div",{key:0,class:"slot-box",onClick:M},[e.renderSlot(t.$slots,"func",{},void 0,!0)])):(e.openBlock(),e.createBlock(s,{key:1,modelValue:e.unref(c),"onUpdate:modelValue":o[0]||(o[0]=i=>e.isRef(c)?c.value=i:c=i),disabled:t.disabled,readonly:t.readonly,clearable:"",onClear:S,placeholder:""},{append:e.withCtx(()=>[e.unref(c)&&t.isClear&&t.readonly?(e.openBlock(),e.createBlock(a,{key:0,onClickCapture:S},{default:e.withCtx(()=>[e.createVNode(l)]),_:1})):e.createCommentVNode("",!0),e.createVNode(r,{type:"primary",disabled:t.disabled,onClick:E},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.buttonText),1)]),_:1},8,["disabled"])]),_:1},8,["modelValue","disabled","readonly"])),e.createVNode(re,{title:"单位选择",modelValue:e.unref(g),"onUpdate:modelValue":o[2]||(o[2]=i=>e.isRef(g)?g.value=i:g=i),onClose:I,width:1e3},{default:e.withCtx(()=>[e.createElementVNode("div",R,[e.createElementVNode("div",Z,[e.createElementVNode("div",D,[K,e.createVNode(s,{modelValue:e.unref(h),"onUpdate:modelValue":o[1]||(o[1]=i=>e.isRef(h)?h.value=i:h=i),"suffix-icon":"Search",onInput:H,placeholder:"请输入单位名称查询"},null,8,["modelValue"])]),e.createElementVNode("div",F,[e.createVNode(w,{data:e.unref(y),ref_key:"orgTree",ref:d,"node-key":"id",props:G,"expand-on-click-node":!1,"show-checkbox":t.multiple,"check-strictly":!0,"highlight-current":!0,accordion:!0,"check-on-click-node":!0,"filter-node-method":W,indent:26,onCheck:ee,"render-content":L,"icon-class":"el-icon-arrow-right"},null,8,["data","show-checkbox"])])]),e.createElementVNode("div",z,[e.createElementVNode("div",{class:"selected-box"},[O,e.createElementVNode("div",{title:"删除全部"},[e.createElementVNode("i",{onClick:B,class:"delete-btn"})])]),e.createElementVNode("div",null,[e.createElementVNode("div",Q,[e.createElementVNode("ul",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(p),(i,T)=>(e.openBlock(),e.createElementBlock("li",{key:T+"s",title:i.orgName+"("+i.id+")"},[e.createElementVNode("span",P,e.toDisplayString(i.orgName)+"("+e.toDisplayString(i.id)+") ",1),e.createVNode(a,{onClick:ce=>te(i,T),color:"#909399",size:"16"},{default:e.withCtx(()=>[e.createVNode(ne)]),_:2},1032,["onClick"])],8,U))),128))])])])])]),e.createElementVNode("div",j,[e.createVNode(r,{onClick:I},{default:e.withCtx(()=>[e.createTextVNode("取消")]),_:1}),e.createVNode(r,{type:"primary",onClick:oe},{default:e.withCtx(()=>[e.createTextVNode("确认")]),_:1})])]),_:1},8,["modelValue"])])}}}),ie="";return((f,u)=>{const n=f.__vccOpts||f;for(const[m,C]of u)n[m]=C;return n})(Y,[["__scopeId","data-v-e2b739c9"]])});
|
package/package.json
CHANGED
@@ -1,10 +1,9 @@
|
|
1
1
|
{
|
2
2
|
"name": "kso-sel-org",
|
3
|
-
"version": "1.0.
|
3
|
+
"version": "1.0.6",
|
4
4
|
"description": "机构选择",
|
5
5
|
"main": "dist/index.umd.js",
|
6
6
|
"module": "dist/index.es.js",
|
7
|
-
"style": "dist/style.css",
|
8
7
|
"types": "dist/index.d.ts",
|
9
8
|
"files": [
|
10
9
|
"dist"
|
@@ -20,7 +19,7 @@
|
|
20
19
|
"element-plus": "^2.3.8",
|
21
20
|
"element-resize-detector": "^1.2.4",
|
22
21
|
"kso-dic": "^1.0.0",
|
23
|
-
"kso-sel-org": "^1.0.
|
22
|
+
"kso-sel-org": "^1.0.5",
|
24
23
|
"kso-sel-reg": "^1.0.1",
|
25
24
|
"less": "^4.1.3",
|
26
25
|
"less-loader": "^11.1.3",
|
@@ -36,10 +35,13 @@
|
|
36
35
|
"devDependencies": {
|
37
36
|
"@types/node": "^20.3.3",
|
38
37
|
"@vitejs/plugin-vue": "^4.1.0",
|
38
|
+
"css-loader": "^6.8.1",
|
39
39
|
"sass": "^1.69.5",
|
40
40
|
"typescript": "^5.0.2",
|
41
41
|
"vite": "^4.3.9",
|
42
42
|
"vite-plugin-eslint": "^1.8.1",
|
43
|
+
"vue-loader": "^17.3.1",
|
44
|
+
"vue-style-loader": "^4.1.3",
|
43
45
|
"vue-tsc": "^1.4.2"
|
44
46
|
},
|
45
47
|
"keywords": [
|
File without changes
|