@ctzy-web-client/plugin-component-vue 1.0.22 → 1.0.24
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/es/advance-select/advance-operation.mjs +51 -37
- package/es/advance-select/advance-option.mjs +167 -97
- package/es/advance-select/advance-option.vue_vue_type_style_index_0_scoped_bc8f5626_lang.mjs +7 -0
- package/es/advance-select/advance-select.mjs +368 -310
- package/es/advance-select/index.mjs +5 -5
- package/es/application-slot/breadcrumb-item.mjs +20 -17
- package/es/application-slot/header-tools-item.mjs +20 -17
- package/es/breadcrumb-select/breadcrumb-select.mjs +134 -112
- package/es/contextmenu/contextmenu-item.mjs +19 -15
- package/es/contextmenu/contextmenu.mjs +72 -56
- package/es/data-form/data-form-item.mjs +48 -30
- package/es/data-form/data-form.mjs +213 -166
- package/es/data-form/form-components/bwa-date-picker.mjs +51 -39
- package/es/data-form/form-components/bwa-date-time-picker.mjs +56 -44
- package/es/data-form/form-components/bwa-input-float.mjs +48 -37
- package/es/data-form/form-components/bwa-input-integer.mjs +68 -50
- package/es/data-form/form-components/bwa-input.mjs +43 -32
- package/es/data-form/form-components/bwa-multi-select.mjs +40 -29
- package/es/data-form/form-components/bwa-rich-text-tinymce.mjs +554 -218
- package/es/data-form/form-components/bwa-rich-text.mjs +404 -316
- package/es/data-form/form-components/bwa-select.mjs +84 -70
- package/es/data-form/form-components/bwa-textarea.mjs +38 -27
- package/es/data-form/form-components/bwa-upload.mjs +172 -148
- package/es/data-form/form-components/bwa-user-multi-select.mjs +35 -24
- package/es/data-form/form-components/bwa-user-select.mjs +86 -61
- package/es/data-table/data-column-view.mjs +146 -115
- package/es/data-table/data-table-card.mjs +48 -40
- package/es/data-table/data-table-column.mjs +58 -45
- package/es/data-table/data-table.mjs +402 -316
- package/es/datatable-settings/datatable-settings.mjs +329 -254
- package/es/date-range/date-picker.mjs +130 -116
- package/es/date-range/date-range.mjs +215 -168
- package/es/drag-list/drag-item.mjs +56 -42
- package/es/drag-list/drag-list.mjs +60 -47
- package/es/dragable/dragable-item.mjs +23 -18
- package/es/dragable/dragable-operation.mjs +32 -24
- package/es/dragable/dragable.mjs +32 -23
- package/es/filter-panel/conditions/date-range-condition.mjs +50 -40
- package/es/filter-panel/conditions/department-condition/department-condition.mjs +99 -72
- package/es/filter-panel/conditions/department-condition/department-node.mjs +73 -59
- package/es/filter-panel/conditions/input-condition.mjs +90 -76
- package/es/filter-panel/conditions/multi-user-condition.mjs +67 -57
- package/es/filter-panel/conditions/multiple-menu-condition.mjs +54 -35
- package/es/filter-panel/conditions/single-menu-condition.mjs +65 -60
- package/es/filter-panel/conditions/single-user-condition.mjs +67 -57
- package/es/filter-panel/filter-panel-item.mjs +54 -39
- package/es/filter-panel/filter-panel.mjs +153 -135
- package/es/layout/layout.mjs +85 -78
- package/es/menu/menu-item.mjs +67 -52
- package/es/menu/menu.mjs +70 -53
- package/es/node_modules/.pnpm/style-inject@0.3.0/node_modules/style-inject/dist/style-inject.es.mjs +28 -0
- package/es/panel/panel.mjs +53 -40
- package/es/pct-filter-panel/pct-compents/pct-Input-condition.mjs +74 -63
- package/es/pct-filter-panel/pct-compents/pct-date-range-condition.mjs +76 -67
- package/es/pct-filter-panel/pct-compents/pct-multiple-menu-condition.mjs +406 -178
- package/es/pct-filter-panel/pct-compents/pct-multiple-menu-condition2.mjs +153 -138
- package/es/pct-filter-panel/pct-filter-panel-item.mjs +55 -40
- package/es/pct-filter-panel/pct-filter-panel.mjs +247 -227
- package/es/progress/progress-item.mjs +81 -61
- package/es/progress/progress.mjs +78 -64
- package/es/where-filter-panel/where-filter-panel.mjs +15 -12
- package/lib/advance-select/advance-operation.js +50 -36
- package/lib/advance-select/advance-option.js +166 -96
- package/lib/advance-select/advance-option.vue_vue_type_style_index_0_scoped_bc8f5626_lang.js +12 -0
- package/lib/advance-select/advance-select.js +366 -308
- package/lib/application-slot/breadcrumb-item.js +19 -16
- package/lib/application-slot/header-tools-item.js +19 -16
- package/lib/breadcrumb-select/breadcrumb-select.js +133 -111
- package/lib/contextmenu/contextmenu-item.js +18 -14
- package/lib/contextmenu/contextmenu.js +71 -55
- package/lib/data-form/data-form-item.js +47 -29
- package/lib/data-form/data-form.js +212 -165
- package/lib/data-form/form-components/bwa-date-picker.js +50 -38
- package/lib/data-form/form-components/bwa-date-time-picker.js +55 -43
- package/lib/data-form/form-components/bwa-input-float.js +47 -36
- package/lib/data-form/form-components/bwa-input-integer.js +67 -49
- package/lib/data-form/form-components/bwa-input.js +42 -31
- package/lib/data-form/form-components/bwa-multi-select.js +39 -28
- package/lib/data-form/form-components/bwa-rich-text-tinymce.js +553 -217
- package/lib/data-form/form-components/bwa-rich-text.js +403 -315
- package/lib/data-form/form-components/bwa-select.js +83 -69
- package/lib/data-form/form-components/bwa-textarea.js +37 -26
- package/lib/data-form/form-components/bwa-upload.js +171 -147
- package/lib/data-form/form-components/bwa-user-multi-select.js +34 -23
- package/lib/data-form/form-components/bwa-user-select.js +85 -60
- package/lib/data-table/data-column-view.js +146 -115
- package/lib/data-table/data-table-card.js +48 -40
- package/lib/data-table/data-table-column.js +57 -44
- package/lib/data-table/data-table.js +401 -315
- package/lib/datatable-settings/datatable-settings.js +328 -253
- package/lib/date-range/date-picker.js +129 -115
- package/lib/date-range/date-range.js +213 -170
- package/lib/drag-list/drag-item.js +55 -41
- package/lib/drag-list/drag-list.js +59 -46
- package/lib/dragable/dragable-item.js +22 -17
- package/lib/dragable/dragable-operation.js +31 -23
- package/lib/dragable/dragable.js +31 -22
- package/lib/filter-panel/conditions/date-range-condition.js +49 -39
- package/lib/filter-panel/conditions/department-condition/department-condition.js +98 -71
- package/lib/filter-panel/conditions/department-condition/department-node.js +72 -58
- package/lib/filter-panel/conditions/input-condition.js +89 -75
- package/lib/filter-panel/conditions/multi-user-condition.js +66 -56
- package/lib/filter-panel/conditions/multiple-menu-condition.js +53 -34
- package/lib/filter-panel/conditions/single-menu-condition.js +64 -59
- package/lib/filter-panel/conditions/single-user-condition.js +66 -56
- package/lib/filter-panel/filter-panel-item.js +53 -38
- package/lib/filter-panel/filter-panel.js +152 -134
- package/lib/layout/layout.js +84 -77
- package/lib/menu/menu-item.js +66 -51
- package/lib/menu/menu.js +69 -52
- package/lib/node_modules/.pnpm/style-inject@0.3.0/node_modules/style-inject/dist/style-inject.es.js +32 -0
- package/lib/panel/panel.js +52 -39
- package/lib/pct-filter-panel/pct-compents/pct-Input-condition.js +73 -62
- package/lib/pct-filter-panel/pct-compents/pct-date-range-condition.js +75 -66
- package/lib/pct-filter-panel/pct-compents/pct-multiple-menu-condition.js +405 -177
- package/lib/pct-filter-panel/pct-compents/pct-multiple-menu-condition2.js +152 -137
- package/lib/pct-filter-panel/pct-filter-panel-item.js +54 -39
- package/lib/pct-filter-panel/pct-filter-panel.js +246 -226
- package/lib/progress/progress-item.js +80 -60
- package/lib/progress/progress.js +77 -63
- package/lib/where-filter-panel/where-filter-panel.js +14 -11
- package/package.json +2 -1
- package/src/advance-select/advance-option.vue +64 -13
- package/src/data-form/form-components/bwa-rich-text-tinymce.vue +1 -1
- package/src/datatable-settings/datatable-settings.vue +33 -3
- package/src/date-range/date-picker.vue +1 -1
- package/src/date-range/date-range.vue +3 -3
- package/src/filter-panel/filter-panel.vue +2 -2
- package/src/pct-filter-panel/pct-compents/pct-Input-condition.vue +64 -64
- package/src/pct-filter-panel/pct-compents/pct-date-range-condition.vue +61 -61
- package/src/pct-filter-panel/pct-compents/pct-multiple-menu-condition.vue +302 -178
- package/src/pct-filter-panel/pct-filter-panel.vue +4 -4
|
@@ -1,186 +1,414 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { ref, onMounted, nextTick, useAttrs, computed, inject, unref, watch, resolveComponent, openBlock, createElementBlock, normalizeClass, toDisplayString, createCommentVNode, createVNode, isRef, withCtx, createTextVNode, createElementVNode, Fragment, renderList, createBlock, withModifiers, renderSlot } from 'vue';
|
|
2
|
+
import { ElTooltip, ElTag, ElIcon, ElInput } from 'element-plus';
|
|
3
|
+
import { ArrowUp, ArrowDown } from '@element-plus/icons';
|
|
2
4
|
import { useService, HttpRequest, useNamespace, filterPanelItemKey } from '@ctzy-web-client/web-base-client-vue';
|
|
3
5
|
import { dataProps } from '../../hooks/use-data/index.mjs';
|
|
6
|
+
import BwaAdvanceSelect from '../../advance-select/advance-select.mjs';
|
|
7
|
+
import BwaAdvanceOption from '../../advance-select/advance-option.mjs';
|
|
4
8
|
import _export_sfc from '../../_virtual/_plugin-vue_export-helper.mjs';
|
|
5
9
|
|
|
6
|
-
const
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
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
|
-
isRequiredByVisibleChange: {
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
}
|
|
61
|
-
|
|
62
|
-
emits: [
|
|
10
|
+
const _hoisted_1 = { key: 0 };
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
const _sfc_main = {
|
|
14
|
+
__name: 'pct-multiple-menu-condition',
|
|
15
|
+
props: {
|
|
16
|
+
...dataProps,
|
|
17
|
+
modelValue: {
|
|
18
|
+
type: null,
|
|
19
|
+
},
|
|
20
|
+
options: {
|
|
21
|
+
type: Array,
|
|
22
|
+
default: () => [],
|
|
23
|
+
},
|
|
24
|
+
labelProp: {
|
|
25
|
+
type: String,
|
|
26
|
+
default: 'label',
|
|
27
|
+
},
|
|
28
|
+
valueProp: {
|
|
29
|
+
type: String,
|
|
30
|
+
default: 'value',
|
|
31
|
+
},
|
|
32
|
+
multiple: {
|
|
33
|
+
type: Boolean,
|
|
34
|
+
default: true,
|
|
35
|
+
},
|
|
36
|
+
showSearch: {
|
|
37
|
+
type: Boolean,
|
|
38
|
+
default: true,
|
|
39
|
+
},
|
|
40
|
+
placeholder: {
|
|
41
|
+
type: String,
|
|
42
|
+
default: '请选择',
|
|
43
|
+
},
|
|
44
|
+
remote: {
|
|
45
|
+
type: Boolean,
|
|
46
|
+
default: true,
|
|
47
|
+
},
|
|
48
|
+
size: {
|
|
49
|
+
type: String,
|
|
50
|
+
default: 'small',
|
|
51
|
+
},
|
|
52
|
+
searchPlaceholder: {
|
|
53
|
+
type: String,
|
|
54
|
+
default: '',
|
|
55
|
+
},
|
|
56
|
+
labelAttr: '',
|
|
57
|
+
valueAttr: '',
|
|
58
|
+
searchAttr: '',
|
|
59
|
+
itfInfo: null,
|
|
60
|
+
// 自定义选项时 是否通过展开自动触发自定义search
|
|
61
|
+
isRequiredByVisibleChange: {
|
|
62
|
+
type: Boolean,
|
|
63
|
+
default: false,
|
|
64
|
+
},
|
|
65
|
+
},
|
|
66
|
+
emits: ['update:modelValue', 'search'],
|
|
63
67
|
setup(__props, { expose, emit }) {
|
|
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
|
-
|
|
68
|
+
|
|
69
|
+
const props = __props;
|
|
70
|
+
|
|
71
|
+
const httpRequest = useService(HttpRequest);
|
|
72
|
+
defineOptions({
|
|
73
|
+
name: 'BwaPctMultipleMenuCondition',
|
|
74
|
+
__conditionTitle__: '多选列表',
|
|
75
|
+
__conditionDefault__: () => [],
|
|
76
|
+
});
|
|
77
|
+
|
|
78
|
+
|
|
79
|
+
const popperWidth = ref('240px');
|
|
80
|
+
onMounted(() => {
|
|
81
|
+
nextTick(() => {
|
|
82
|
+
const offsetWidth = document.getElementsByClassName('bwa-pctfilterpanel-item__options')[0]?.offsetWidth;
|
|
83
|
+
if (offsetWidth > 0) {
|
|
84
|
+
popperWidth.value = offsetWidth + 'px';
|
|
85
|
+
}
|
|
86
|
+
});
|
|
87
|
+
});
|
|
88
|
+
const ns = useNamespace('pctfilterpanel-item');
|
|
89
|
+
const isShowPopper = ref(false);
|
|
90
|
+
const isHoverIcon = ref(false);
|
|
91
|
+
|
|
92
|
+
const attrs = useAttrs();
|
|
93
|
+
const showTitle = computed(() => attrs.showTitle);
|
|
94
|
+
|
|
95
|
+
const data = ref([]);
|
|
96
|
+
const loading = ref(false);
|
|
97
|
+
|
|
98
|
+
|
|
99
|
+
const filterPanelItem = inject(filterPanelItemKey, null);
|
|
100
|
+
const column = computed(() => filterPanelItem?.column ?? null);
|
|
101
|
+
|
|
102
|
+
/**
|
|
103
|
+
* 页面参数层级覆盖配置文件传递的参数层级
|
|
104
|
+
*/
|
|
105
|
+
if (props.itfInfo) {
|
|
106
|
+
column.value.componentProps = {
|
|
107
|
+
itfInfo: props.itfInfo || {},
|
|
108
|
+
labelAttr: props.labelAttr || 'label',
|
|
109
|
+
valueAttr: props.valueAttr || 'value',
|
|
110
|
+
searchAttr: props.searchAttr || 'search'
|
|
111
|
+
};
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
const searchPlaceholderStr = computed(() => column.value?.componentProps?.searchPlaceholder || props.searchPlaceholder);
|
|
115
|
+
const placeholderStr = computed(() => showTitle.value ? props.placeholder : column.value.title);
|
|
116
|
+
|
|
117
|
+
const labelPropStr = computed(() => column.value?.componentProps?.labelAttr || props.labelProp);
|
|
118
|
+
const valuePropStr = computed(() => column.value?.componentProps?.valueAttr || props.valueProp);
|
|
119
|
+
const handleClose = (val)=>{
|
|
120
|
+
|
|
121
|
+
// 优化后
|
|
122
|
+
// 1. 空值兜底:避免 modelValue.value 为 null/undefined 时报错
|
|
123
|
+
const currentModelValue = Array.isArray(modelValue.value) ? modelValue.value : [];
|
|
124
|
+
// 2. 严格相等 + 类型统一:解决 1 vs "1" 不匹配,同时避免隐式类型转换
|
|
125
|
+
modelValue.value = currentModelValue.filter(item =>
|
|
126
|
+
String(item) !== String(val.value)
|
|
127
|
+
);
|
|
128
|
+
|
|
129
|
+
};
|
|
130
|
+
const handleIconClick = () => {
|
|
131
|
+
if (isHoverIcon.value) {
|
|
132
|
+
// 多选清空逻辑:重置 modelValue 为空数组
|
|
133
|
+
modelValue.value = [];
|
|
134
|
+
isHoverIcon.value = false; // 重置悬浮状态
|
|
135
|
+
return;
|
|
136
|
+
}
|
|
137
|
+
// 原有逻辑:切换下拉显隐
|
|
138
|
+
isShowPopper.value = !isShowPopper.value;
|
|
139
|
+
};
|
|
140
|
+
const getData = async (query) => {
|
|
141
|
+
loading.value = true;
|
|
142
|
+
const { itfInfo, searchAttr } = column.value.componentProps;
|
|
143
|
+
const {url, method, options, params } = {
|
|
144
|
+
url: unref(itfInfo).url,
|
|
145
|
+
method: unref(itfInfo).method || 'POST',
|
|
146
|
+
options: unref(itfInfo).options || {},
|
|
147
|
+
params: { ...unref(itfInfo).params, [searchAttr]: query || ''} || {},
|
|
148
|
+
};
|
|
149
|
+
data.value = (await unref(httpRequest)[method.toLowerCase()](url, params, options))?.data;
|
|
150
|
+
loading.value = false;
|
|
151
|
+
};
|
|
152
|
+
|
|
153
|
+
data.value = props.options ?? [];
|
|
154
|
+
const visibleChange = (val) => {
|
|
155
|
+
isShowPopper.value = val;
|
|
156
|
+
if (!val || !column.value.componentProps || column.value?.componentProps?.options) {
|
|
157
|
+
if (isShowPopper.value && props.isRequiredByVisibleChange) {
|
|
158
|
+
emit('search', '');
|
|
159
|
+
}
|
|
160
|
+
return
|
|
161
|
+
}
|
|
162
|
+
getData();
|
|
163
|
+
};
|
|
164
|
+
|
|
165
|
+
const handleFieldSearch = (query) => {
|
|
166
|
+
if (column.value.componentProps) {
|
|
167
|
+
getData(query);
|
|
168
|
+
} else {
|
|
169
|
+
emit('search', query);
|
|
170
|
+
}
|
|
171
|
+
};
|
|
172
|
+
|
|
173
|
+
const search = ref('');
|
|
174
|
+
watch(() => search.value, val => {
|
|
175
|
+
handleFieldSearch(val);
|
|
176
|
+
});
|
|
177
|
+
|
|
178
|
+
const modelValue = computed({
|
|
179
|
+
get: () => {
|
|
180
|
+
if (props.multiple) {
|
|
181
|
+
return Array.isArray(props.modelValue)
|
|
182
|
+
? props.modelValue.map((item) => item )
|
|
183
|
+
: [];
|
|
184
|
+
} else {
|
|
185
|
+
return props.modelValue == null || Array.isArray(props.modelValue) ? '' : props.modelValue;
|
|
186
|
+
}
|
|
187
|
+
},
|
|
188
|
+
set: (v) => emit('update:modelValue', v),
|
|
189
|
+
});
|
|
190
|
+
|
|
191
|
+
/**
|
|
192
|
+
* 清除已选
|
|
193
|
+
*/
|
|
194
|
+
const advanceSelectRef = ref(null);
|
|
195
|
+
const handleClearClick = () => {
|
|
196
|
+
if (advanceSelectRef.value) {
|
|
197
|
+
advanceSelectRef.value.handleClearClick();
|
|
198
|
+
}
|
|
199
|
+
};
|
|
200
|
+
|
|
201
|
+
expose({
|
|
202
|
+
data
|
|
203
|
+
});
|
|
204
|
+
|
|
205
|
+
return (_ctx, _cache) => {
|
|
206
|
+
const _component_CircleClose = resolveComponent("CircleClose");
|
|
207
|
+
|
|
208
|
+
return (openBlock(), createElementBlock("div", {
|
|
209
|
+
class: normalizeClass(unref(ns).e('conditbox'))
|
|
210
|
+
}, [
|
|
211
|
+
(unref(showTitle))
|
|
212
|
+
? (openBlock(), createElementBlock("div", {
|
|
152
213
|
key: 0,
|
|
153
|
-
class: normalizeClass(unref(ns).e(
|
|
154
|
-
}, toDisplayString(unref(column).title), 3
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
214
|
+
class: normalizeClass(unref(ns).e('title'))
|
|
215
|
+
}, toDisplayString(unref(column).title), 3 /* TEXT, CLASS */))
|
|
216
|
+
: createCommentVNode("v-if", true),
|
|
217
|
+
createVNode(BwaAdvanceSelect, {
|
|
218
|
+
multiple: __props.multiple,
|
|
219
|
+
modelValue: unref(modelValue),
|
|
220
|
+
"onUpdate:modelValue": _cache[3] || (_cache[3] = $event => (isRef(modelValue) ? (modelValue).value = $event : null)),
|
|
221
|
+
onSearch: handleFieldSearch,
|
|
222
|
+
class: normalizeClass(unref(ns).e('options')),
|
|
223
|
+
onVisibleChange: visibleChange,
|
|
224
|
+
source: "pct",
|
|
225
|
+
showSearch: false,
|
|
226
|
+
showSelectIcon: !__props.multiple,
|
|
227
|
+
showSelection: false,
|
|
228
|
+
loading: loading.value,
|
|
229
|
+
width: popperWidth.value,
|
|
230
|
+
borderRadius: "4px",
|
|
231
|
+
ref_key: "advanceSelectRef",
|
|
232
|
+
ref: advanceSelectRef
|
|
233
|
+
}, {
|
|
234
|
+
"reference-content": withCtx(({ selected }) => [
|
|
235
|
+
(__props.multiple)
|
|
236
|
+
? (openBlock(), createElementBlock("div", {
|
|
237
|
+
key: 0,
|
|
238
|
+
class: normalizeClass(unref(ns).e('content'))
|
|
239
|
+
}, [
|
|
240
|
+
(selected && selected.length > 0)
|
|
241
|
+
? (openBlock(), createElementBlock("div", _hoisted_1, [
|
|
242
|
+
createVNode(unref(ElTooltip), {
|
|
243
|
+
content: selected[0].label,
|
|
244
|
+
placement: "top",
|
|
245
|
+
effect: "light",
|
|
246
|
+
"append-to": ".bwa-application"
|
|
247
|
+
}, {
|
|
248
|
+
default: withCtx(() => [
|
|
249
|
+
createVNode(unref(ElTag), {
|
|
250
|
+
class: normalizeClass(unref(ns).e('tag')),
|
|
251
|
+
closable: "",
|
|
252
|
+
onClose: $event => (handleClose(selected[0])),
|
|
253
|
+
type: "info"
|
|
254
|
+
}, {
|
|
255
|
+
default: withCtx(() => [
|
|
256
|
+
createTextVNode(toDisplayString(selected[0].label), 1 /* TEXT */)
|
|
257
|
+
]),
|
|
258
|
+
_: 2 /* DYNAMIC */
|
|
259
|
+
}, 1032 /* PROPS, DYNAMIC_SLOTS */, ["class", "onClose"])
|
|
260
|
+
]),
|
|
261
|
+
_: 2 /* DYNAMIC */
|
|
262
|
+
}, 1032 /* PROPS, DYNAMIC_SLOTS */, ["content"]),
|
|
263
|
+
createVNode(unref(ElTooltip), {
|
|
264
|
+
content: "Bottom center",
|
|
265
|
+
placement: "top",
|
|
266
|
+
effect: "light",
|
|
267
|
+
"append-to": ".bwa-application"
|
|
268
|
+
}, {
|
|
269
|
+
content: withCtx(() => [
|
|
270
|
+
createElementVNode("div", {
|
|
271
|
+
class: normalizeClass(unref(ns).e('tag_box'))
|
|
272
|
+
}, [
|
|
273
|
+
(openBlock(true), createElementBlock(Fragment, null, renderList(selected, (item, index) => {
|
|
274
|
+
return (openBlock(), createElementBlock(Fragment, null, [
|
|
275
|
+
(index !== 0)
|
|
276
|
+
? (openBlock(), createBlock(unref(ElTag), {
|
|
277
|
+
key: 0,
|
|
278
|
+
class: normalizeClass(unref(ns).e('tag_details')),
|
|
279
|
+
type: "info",
|
|
280
|
+
closable: "",
|
|
281
|
+
onClose: $event => (handleClose(item))
|
|
282
|
+
}, {
|
|
283
|
+
default: withCtx(() => [
|
|
284
|
+
createTextVNode(toDisplayString(item.label), 1 /* TEXT */)
|
|
285
|
+
]),
|
|
286
|
+
_: 2 /* DYNAMIC */
|
|
287
|
+
}, 1032 /* PROPS, DYNAMIC_SLOTS */, ["class", "onClose"]))
|
|
288
|
+
: createCommentVNode("v-if", true)
|
|
289
|
+
], 64 /* STABLE_FRAGMENT */))
|
|
290
|
+
}), 256 /* UNKEYED_FRAGMENT */))
|
|
291
|
+
], 2 /* CLASS */)
|
|
292
|
+
]),
|
|
293
|
+
default: withCtx(() => [
|
|
294
|
+
(selected.length > 1)
|
|
295
|
+
? (openBlock(), createBlock(unref(ElTag), {
|
|
296
|
+
key: 0,
|
|
297
|
+
class: normalizeClass(unref(ns).e('tag')),
|
|
298
|
+
type: "info"
|
|
299
|
+
}, {
|
|
300
|
+
default: withCtx(() => [
|
|
301
|
+
createTextVNode("+" + toDisplayString(selected.length - 1), 1 /* TEXT */)
|
|
302
|
+
]),
|
|
303
|
+
_: 2 /* DYNAMIC */
|
|
304
|
+
}, 1032 /* PROPS, DYNAMIC_SLOTS */, ["class"]))
|
|
305
|
+
: createCommentVNode("v-if", true)
|
|
306
|
+
]),
|
|
307
|
+
_: 2 /* DYNAMIC */
|
|
308
|
+
}, 1024 /* DYNAMIC_SLOTS */)
|
|
309
|
+
]))
|
|
310
|
+
: (openBlock(), createElementBlock("div", {
|
|
311
|
+
key: 1,
|
|
312
|
+
class: normalizeClass(unref(ns).e('contentBox_placeholder'))
|
|
313
|
+
}, toDisplayString(unref(placeholderStr)), 3 /* TEXT, CLASS */)),
|
|
314
|
+
createVNode(unref(ElIcon), {
|
|
315
|
+
onMouseenter: _cache[0] || (_cache[0] = $event => (isHoverIcon.value = true)),
|
|
316
|
+
onMouseleave: _cache[1] || (_cache[1] = $event => (isHoverIcon.value = false)),
|
|
317
|
+
onClick: withModifiers(handleIconClick, ["stop"]),
|
|
318
|
+
class: normalizeClass(unref(ns).be('option', 'selected'))
|
|
319
|
+
}, {
|
|
320
|
+
default: withCtx(() => [
|
|
321
|
+
(isHoverIcon.value && selected.length > 0)
|
|
322
|
+
? (openBlock(), createBlock(_component_CircleClose, {
|
|
323
|
+
key: 0,
|
|
324
|
+
class: "delete-icon"
|
|
325
|
+
}))
|
|
326
|
+
: (isShowPopper.value)
|
|
327
|
+
? (openBlock(), createBlock(unref(ArrowUp), { key: 1 }))
|
|
328
|
+
: (openBlock(), createBlock(unref(ArrowDown), { key: 2 }))
|
|
329
|
+
]),
|
|
330
|
+
_: 2 /* DYNAMIC */
|
|
331
|
+
}, 1032 /* PROPS, DYNAMIC_SLOTS */, ["onClick", "class"])
|
|
332
|
+
], 2 /* CLASS */))
|
|
333
|
+
: (openBlock(), createElementBlock("div", {
|
|
334
|
+
key: 1,
|
|
335
|
+
class: normalizeClass(unref(ns).e('content'))
|
|
336
|
+
}, [
|
|
337
|
+
createVNode(unref(ElTooltip), {
|
|
338
|
+
disabled: !selected.label,
|
|
339
|
+
content: selected.label,
|
|
340
|
+
placement: "top",
|
|
341
|
+
effect: "light",
|
|
342
|
+
"append-to": ".bwa-application"
|
|
343
|
+
}, {
|
|
344
|
+
default: withCtx(() => [
|
|
345
|
+
(selected.label)
|
|
346
|
+
? (openBlock(), createElementBlock("div", {
|
|
347
|
+
key: 0,
|
|
348
|
+
class: normalizeClass([unref(ns).e('contentBox'), unref(ns).e('contentBox_label')])
|
|
349
|
+
}, toDisplayString(selected.label || unref(placeholderStr)), 3 /* TEXT, CLASS */))
|
|
350
|
+
: (openBlock(), createElementBlock("div", {
|
|
351
|
+
key: 1,
|
|
352
|
+
class: normalizeClass([unref(ns).e('contentBox'), unref(ns).e('contentBox_placeholder')])
|
|
353
|
+
}, toDisplayString(unref(placeholderStr)), 3 /* TEXT, CLASS */))
|
|
354
|
+
]),
|
|
355
|
+
_: 2 /* DYNAMIC */
|
|
356
|
+
}, 1032 /* PROPS, DYNAMIC_SLOTS */, ["disabled", "content"]),
|
|
357
|
+
createVNode(unref(ElIcon), {
|
|
358
|
+
class: normalizeClass(unref(ns).be('option', 'selected'))
|
|
359
|
+
}, {
|
|
360
|
+
default: withCtx(() => [
|
|
361
|
+
(isShowPopper.value)
|
|
362
|
+
? (openBlock(), createBlock(unref(ArrowUp), { key: 0 }))
|
|
363
|
+
: (openBlock(), createBlock(unref(ArrowDown), { key: 1 }))
|
|
364
|
+
]),
|
|
365
|
+
_: 1 /* STABLE */
|
|
366
|
+
}, 8 /* PROPS */, ["class"])
|
|
367
|
+
], 2 /* CLASS */))
|
|
368
|
+
]),
|
|
369
|
+
contentTop: withCtx(() => [
|
|
370
|
+
(__props.showSearch && !unref(column).componentProps?.options)
|
|
371
|
+
? (openBlock(), createElementBlock("div", {
|
|
372
|
+
key: 0,
|
|
373
|
+
class: normalizeClass(unref(ns).e('contentTop'))
|
|
374
|
+
}, [
|
|
375
|
+
createVNode(unref(ElInput), {
|
|
376
|
+
modelValue: search.value,
|
|
377
|
+
"onUpdate:modelValue": _cache[2] || (_cache[2] = $event => ((search).value = $event)),
|
|
378
|
+
class: normalizeClass(unref(ns).e('select')),
|
|
379
|
+
placeholder: unref(searchPlaceholderStr),
|
|
380
|
+
type: "text",
|
|
381
|
+
"prefix-icon": "Search",
|
|
382
|
+
clearable: ""
|
|
383
|
+
}, null, 8 /* PROPS */, ["modelValue", "class", "placeholder"])
|
|
384
|
+
], 2 /* CLASS */))
|
|
385
|
+
: createCommentVNode("v-if", true)
|
|
386
|
+
]),
|
|
387
|
+
contentBottom: withCtx(() => [
|
|
388
|
+
createElementVNode("div", {
|
|
389
|
+
class: normalizeClass(unref(ns).e('clear')),
|
|
390
|
+
onClick: handleClearClick
|
|
391
|
+
}, "清除已选", 2 /* CLASS */)
|
|
392
|
+
]),
|
|
393
|
+
default: withCtx(() => [
|
|
394
|
+
renderSlot(_ctx.$slots, "default", {}, () => [
|
|
395
|
+
(openBlock(true), createElementBlock(Fragment, null, renderList(data.value, (item) => {
|
|
396
|
+
return (openBlock(), createBlock(BwaAdvanceOption, {
|
|
397
|
+
key: item[unref(valuePropStr)] + '',
|
|
398
|
+
value: item[unref(valuePropStr)] + '',
|
|
399
|
+
label: item[unref(labelPropStr)] + '',
|
|
400
|
+
class: normalizeClass(unref(ns).be('filter', 'option'))
|
|
401
|
+
}, null, 8 /* PROPS */, ["value", "label", "class"]))
|
|
402
|
+
}), 128 /* KEYED_FRAGMENT */))
|
|
403
|
+
])
|
|
404
|
+
]),
|
|
405
|
+
_: 3 /* FORWARDED */
|
|
406
|
+
}, 8 /* PROPS */, ["multiple", "modelValue", "class", "showSelectIcon", "loading", "width"])
|
|
407
|
+
], 2 /* CLASS */))
|
|
408
|
+
}
|
|
409
|
+
}
|
|
410
|
+
|
|
411
|
+
};
|
|
412
|
+
var PctMultipleMenuCondition = /*#__PURE__*/_export_sfc(_sfc_main, [['__file',"pct-multiple-menu-condition.vue"]]);
|
|
185
413
|
|
|
186
414
|
export { PctMultipleMenuCondition as default };
|