bm-admin-ui 1.0.45-alpha → 1.0.46-alpha
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/components/button/index.d.ts +1 -1
- package/es/components/button/src/button.vue.d.ts +1 -1
- package/es/components/editor/__test__/index.test.d.ts +1 -0
- package/es/components/editor/index.d.ts +1 -1
- package/es/components/editor/src/editor.vue.d.ts +1 -1
- package/es/components/float-table/index.d.ts +1 -1
- package/es/components/float-table/index.js +22 -11
- package/es/components/float-table/src/float-table.vue.d.ts +1 -1
- package/es/components/form-create/index.js +86 -81
- package/es/components/form-designer/index.js +59 -67
- package/es/components/index.d.ts +1 -0
- package/es/components/index.js +1 -0
- package/es/components/search-filter/index.d.ts +3 -3
- package/es/components/search-filter/src/search-filter.vue.d.ts +3 -3
- package/es/components/select-all/index.d.ts +1 -1
- package/es/components/select-all/src/selectAll.vue.d.ts +1 -1
- package/es/components/videoView/__test__/index.test.d.ts +1 -0
- package/es/components/videoView/index.d.ts +37 -0
- package/es/components/videoView/index.js +100 -0
- package/es/components/videoView/src/videoView.vue.d.ts +36 -0
- package/lib/components/button/index.d.ts +1 -1
- package/lib/components/button/src/button.vue.d.ts +1 -1
- package/lib/components/editor/__test__/index.test.d.ts +1 -0
- package/lib/components/editor/index.d.ts +1 -1
- package/lib/components/editor/src/editor.vue.d.ts +1 -1
- package/lib/components/float-table/index.d.ts +1 -1
- package/lib/components/float-table/index.js +22 -11
- package/lib/components/float-table/src/float-table.vue.d.ts +1 -1
- package/lib/components/form-create/index.js +86 -82
- package/lib/components/form-designer/index.js +59 -67
- package/lib/components/index.d.ts +1 -0
- package/lib/components/index.js +7 -0
- package/lib/components/search-filter/index.d.ts +3 -3
- package/lib/components/search-filter/src/search-filter.vue.d.ts +3 -3
- package/lib/components/select-all/index.d.ts +1 -1
- package/lib/components/select-all/src/selectAll.vue.d.ts +1 -1
- package/lib/components/videoView/__test__/index.test.d.ts +1 -0
- package/lib/components/videoView/index.d.ts +37 -0
- package/lib/components/videoView/index.js +105 -0
- package/lib/components/videoView/src/videoView.vue.d.ts +36 -0
- package/package.json +1 -1
- package/theme-chalk/index.css +1 -1
- package/theme-chalk/videoView.css +1 -0
- package/types/components/button/index.d.ts +1 -1
- package/types/components/button/src/button.vue.d.ts +1 -1
- package/types/components/editor/__test__/index.test.d.ts +1 -0
- package/types/components/editor/index.d.ts +1 -1
- package/types/components/editor/src/editor.vue.d.ts +1 -1
- package/types/components/float-table/index.d.ts +1 -1
- package/types/components/float-table/src/float-table.vue.d.ts +1 -1
- package/types/components/index.d.ts +1 -0
- package/types/components/search-filter/index.d.ts +3 -3
- package/types/components/search-filter/src/search-filter.vue.d.ts +3 -3
- package/types/components/select-all/index.d.ts +1 -1
- package/types/components/select-all/src/selectAll.vue.d.ts +1 -1
- package/types/components/videoView/__test__/index.test.d.ts +1 -0
- package/types/components/videoView/index.d.ts +37 -0
- package/types/components/videoView/src/videoView.vue.d.ts +36 -0
- package/index.esm.js +0 -150081
- package/index.js +0 -150115
|
@@ -49,6 +49,7 @@ const _sfc_main = {
|
|
|
49
49
|
"radioChange",
|
|
50
50
|
"checkboxChange",
|
|
51
51
|
"checkboxChangeAll",
|
|
52
|
+
"cellClick",
|
|
52
53
|
"pageChange",
|
|
53
54
|
"pageSizeChange"
|
|
54
55
|
],
|
|
@@ -80,7 +81,7 @@ const _sfc_main = {
|
|
|
80
81
|
reserve: false,
|
|
81
82
|
highlight: vue.computed(function() {
|
|
82
83
|
return props.config.columns.some(function(item) {
|
|
83
|
-
return item.type === "checkbox"
|
|
84
|
+
return item.type === "checkbox";
|
|
84
85
|
});
|
|
85
86
|
}),
|
|
86
87
|
trigger: "row"
|
|
@@ -100,6 +101,16 @@ const _sfc_main = {
|
|
|
100
101
|
},
|
|
101
102
|
checkboxAll(val) {
|
|
102
103
|
emit("checkboxChangeAll", val);
|
|
104
|
+
},
|
|
105
|
+
cellClick(data) {
|
|
106
|
+
let { row, column } = data;
|
|
107
|
+
if (column.type === "checkbox" || column.type === "radio" || column.field === "action" || column.slots?.default === "floatHandle")
|
|
108
|
+
return;
|
|
109
|
+
else {
|
|
110
|
+
xGrid.value.clearCheckboxRow();
|
|
111
|
+
xGrid.value.setCheckboxRow(row, true);
|
|
112
|
+
emit("cellClick", data);
|
|
113
|
+
}
|
|
103
114
|
}
|
|
104
115
|
},
|
|
105
116
|
atVisible: false,
|
|
@@ -110,7 +121,7 @@ const _sfc_main = {
|
|
|
110
121
|
},
|
|
111
122
|
trNodes: [],
|
|
112
123
|
isInScroll: false,
|
|
113
|
-
|
|
124
|
+
inMaxScrollX: false,
|
|
114
125
|
floatRow: {},
|
|
115
126
|
floatRowIndex: void 0,
|
|
116
127
|
floatHandleDomCol: null
|
|
@@ -121,7 +132,7 @@ const _sfc_main = {
|
|
|
121
132
|
"bm-table",
|
|
122
133
|
`table-${props.size}`,
|
|
123
134
|
{
|
|
124
|
-
floatHandleTable: props.isNeedFloatHandle && (!state.atVisible || state.
|
|
135
|
+
floatHandleTable: props.isNeedFloatHandle && (!state.atVisible || state.inMaxScrollX) && state.floatHandleDomCol
|
|
125
136
|
}
|
|
126
137
|
];
|
|
127
138
|
});
|
|
@@ -135,14 +146,14 @@ const _sfc_main = {
|
|
|
135
146
|
const gridEvents = vue.computed(() => {
|
|
136
147
|
let extraFn = {};
|
|
137
148
|
if (props.isNeedFloatHandle) {
|
|
138
|
-
let
|
|
149
|
+
let propsCellMouseenter = props.events.cellMouseenter;
|
|
139
150
|
extraFn.cellMouseenter = (e) => {
|
|
140
151
|
if (props.isNeedFloatHandle) {
|
|
141
152
|
if (state.isInScroll) {
|
|
142
153
|
state.isShowFloatHandle = false;
|
|
143
154
|
return;
|
|
144
155
|
}
|
|
145
|
-
if (state.
|
|
156
|
+
if (state.inMaxScrollX) {
|
|
146
157
|
state.isShowFloatHandle = false;
|
|
147
158
|
}
|
|
148
159
|
let rowid = e.rowid;
|
|
@@ -171,7 +182,7 @@ const _sfc_main = {
|
|
|
171
182
|
top,
|
|
172
183
|
height: clientHeight
|
|
173
184
|
};
|
|
174
|
-
if (!state.atVisible && !state.
|
|
185
|
+
if (!state.atVisible && !state.inMaxScrollX) {
|
|
175
186
|
state.isShowFloatHandle = true;
|
|
176
187
|
}
|
|
177
188
|
vue.nextTick(() => {
|
|
@@ -182,23 +193,23 @@ const _sfc_main = {
|
|
|
182
193
|
});
|
|
183
194
|
}, 200);
|
|
184
195
|
}
|
|
185
|
-
|
|
196
|
+
propsCellMouseenter && propsCellMouseenter(e);
|
|
186
197
|
};
|
|
187
198
|
extraFn.scroll = (e) => {
|
|
188
|
-
let
|
|
199
|
+
let propsScroll = props.events.scroll;
|
|
189
200
|
if (e.isY && props.isNeedFloatHandle) {
|
|
190
201
|
methods.scrollNotShowFloat();
|
|
191
202
|
}
|
|
192
203
|
if (e.isX && props.isNeedFloatHandle && state.floatHandleDomCol && gridOptions.value.data && gridOptions.value.data.length > 0) {
|
|
193
204
|
if (e.scrollLeft + e.$event.target.clientWidth >= e.$event.target.scrollWidth - state.floatHandleDomCol.clientWidth) {
|
|
194
|
-
state.
|
|
205
|
+
state.inMaxScrollX = true;
|
|
195
206
|
state.isShowFloatHandle = false;
|
|
196
207
|
} else {
|
|
197
|
-
state.
|
|
208
|
+
state.inMaxScrollX = false;
|
|
198
209
|
state.isShowFloatHandle = true;
|
|
199
210
|
}
|
|
200
211
|
}
|
|
201
|
-
|
|
212
|
+
propsScroll && propsScroll(e);
|
|
202
213
|
};
|
|
203
214
|
extraFn.cellMouseleave = (e) => {
|
|
204
215
|
let propsCellMouseLeave = props.events.cellMouseleave;
|
|
@@ -58,7 +58,7 @@ declare const _default: {
|
|
|
58
58
|
}>;
|
|
59
59
|
trNodes: import("vue").Ref<any>;
|
|
60
60
|
isInScroll: import("vue").Ref<boolean>;
|
|
61
|
-
|
|
61
|
+
inMaxScrollX: import("vue").Ref<boolean>;
|
|
62
62
|
floatRow: import("vue").Ref<{}>;
|
|
63
63
|
floatRowIndex: import("vue").Ref<undefined>;
|
|
64
64
|
floatHandleDomCol: import("vue").Ref<any>;
|
|
@@ -11,14 +11,12 @@ var BmStaffsSelector = require('bm-admin-ui/lib/components/staffs-selector');
|
|
|
11
11
|
var components = require('bm-admin-ui/lib/components');
|
|
12
12
|
var iconsVue = require('@ant-design/icons-vue');
|
|
13
13
|
var lodashEs = require('lodash-es');
|
|
14
|
-
var FC = require('@form-create/ant-design-vue');
|
|
15
14
|
|
|
16
15
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
17
16
|
|
|
18
17
|
var dayjs__default = /*#__PURE__*/_interopDefaultLegacy(dayjs);
|
|
19
18
|
var Picture__default = /*#__PURE__*/_interopDefaultLegacy(Picture);
|
|
20
19
|
var BmStaffsSelector__default = /*#__PURE__*/_interopDefaultLegacy(BmStaffsSelector);
|
|
21
|
-
var FC__default = /*#__PURE__*/_interopDefaultLegacy(FC);
|
|
22
20
|
|
|
23
21
|
const fieldRatioMap = {
|
|
24
22
|
'25%': 6,
|
|
@@ -785,15 +783,27 @@ const _sfc_main$a = /* @__PURE__ */ vue.defineComponent({
|
|
|
785
783
|
"placeholder",
|
|
786
784
|
"defaultSelected",
|
|
787
785
|
"load",
|
|
788
|
-
"disabled"
|
|
786
|
+
"disabled",
|
|
787
|
+
"fieldNames"
|
|
789
788
|
],
|
|
790
789
|
emits: ["change"],
|
|
791
790
|
setup(__props, { emit: emits }) {
|
|
792
791
|
const props = __props;
|
|
792
|
+
const fieldNames = props.fieldNames || {
|
|
793
|
+
label: "name",
|
|
794
|
+
value: "code"
|
|
795
|
+
};
|
|
793
796
|
const selected = vue.ref([]);
|
|
794
797
|
const visible = vue.ref(false);
|
|
795
798
|
function selectedChange(val) {
|
|
796
|
-
emits(
|
|
799
|
+
emits(
|
|
800
|
+
"change",
|
|
801
|
+
val.map((item) => ({
|
|
802
|
+
[fieldNames.value]: item.key,
|
|
803
|
+
[fieldNames.label]: item.title,
|
|
804
|
+
...item
|
|
805
|
+
}))
|
|
806
|
+
);
|
|
797
807
|
}
|
|
798
808
|
function handleAdd() {
|
|
799
809
|
visible.value = true;
|
|
@@ -838,6 +848,7 @@ var StaffSelector = /* @__PURE__ */ _export_sfc(_sfc_main$a, [["__file", "staff-
|
|
|
838
848
|
var people = {
|
|
839
849
|
name: 'people',
|
|
840
850
|
rule(data, extraConfig) {
|
|
851
|
+
var _a;
|
|
841
852
|
return {
|
|
842
853
|
type: 'StaffSelector',
|
|
843
854
|
component: StaffSelector,
|
|
@@ -853,6 +864,7 @@ var people = {
|
|
|
853
864
|
return yield extraConfig.people.fetch(params);
|
|
854
865
|
});
|
|
855
866
|
},
|
|
867
|
+
fieldNames: (_a = extraConfig.people) === null || _a === void 0 ? void 0 : _a.fieldNames,
|
|
856
868
|
},
|
|
857
869
|
effect: {
|
|
858
870
|
required: data.effect.required && '请选择',
|
|
@@ -877,6 +889,7 @@ var people = {
|
|
|
877
889
|
};
|
|
878
890
|
},
|
|
879
891
|
rowRule(data, extraConfig) {
|
|
892
|
+
var _a;
|
|
880
893
|
return {
|
|
881
894
|
type: 'StaffSelector',
|
|
882
895
|
component: StaffSelector,
|
|
@@ -892,6 +905,7 @@ var people = {
|
|
|
892
905
|
return yield extraConfig.people.fetch(params);
|
|
893
906
|
});
|
|
894
907
|
},
|
|
908
|
+
fieldNames: (_a = extraConfig.people) === null || _a === void 0 ? void 0 : _a.fieldNames,
|
|
895
909
|
},
|
|
896
910
|
effect: {
|
|
897
911
|
required: data.effect.required && '请选择',
|
|
@@ -2238,7 +2252,11 @@ const _sfc_main$4 = /* @__PURE__ */ vue.defineComponent({
|
|
|
2238
2252
|
emits: ["change"],
|
|
2239
2253
|
setup(__props, { emit: emits }) {
|
|
2240
2254
|
const props = __props;
|
|
2241
|
-
const
|
|
2255
|
+
const fieldNames = props.extraConfig.fieldNames || {
|
|
2256
|
+
label: "name",
|
|
2257
|
+
value: "code"
|
|
2258
|
+
};
|
|
2259
|
+
const value = vue.ref(props.value?.[fieldNames.value]);
|
|
2242
2260
|
const options = vue.ref([]);
|
|
2243
2261
|
const keyword = vue.ref("");
|
|
2244
2262
|
const debounceFetch = lodashEs.debounce((value2) => {
|
|
@@ -2258,7 +2276,10 @@ const _sfc_main$4 = /* @__PURE__ */ vue.defineComponent({
|
|
|
2258
2276
|
}
|
|
2259
2277
|
function handleChange(val, option) {
|
|
2260
2278
|
value.value = val;
|
|
2261
|
-
emits("change",
|
|
2279
|
+
emits("change", {
|
|
2280
|
+
[fieldNames.value]: option.value,
|
|
2281
|
+
[fieldNames.label]: option.label
|
|
2282
|
+
});
|
|
2262
2283
|
}
|
|
2263
2284
|
function handleSearch(value2) {
|
|
2264
2285
|
keyword.value = value2;
|
|
@@ -2377,7 +2398,7 @@ var shop = {
|
|
|
2377
2398
|
};
|
|
2378
2399
|
|
|
2379
2400
|
const _sfc_main$3 = /* @__PURE__ */ vue.defineComponent({
|
|
2380
|
-
__name: "material-type
|
|
2401
|
+
__name: "material-type",
|
|
2381
2402
|
props: ["config", "multiple", "format", "value"],
|
|
2382
2403
|
emits: ["change"],
|
|
2383
2404
|
setup(__props, { emit: emits }) {
|
|
@@ -2402,58 +2423,65 @@ const _sfc_main$3 = /* @__PURE__ */ vue.defineComponent({
|
|
|
2402
2423
|
result.forEach((item) => {
|
|
2403
2424
|
item.isLeaf = props.format === optionLength + 1;
|
|
2404
2425
|
});
|
|
2405
|
-
|
|
2426
|
+
if (result.length) {
|
|
2427
|
+
targetOption.children = result;
|
|
2428
|
+
} else {
|
|
2429
|
+
targetOption.isLeaf = true;
|
|
2430
|
+
}
|
|
2406
2431
|
}).finally(() => {
|
|
2407
2432
|
targetOption.loading = false;
|
|
2408
2433
|
});
|
|
2409
2434
|
}
|
|
2410
|
-
function handleChange(
|
|
2411
|
-
|
|
2435
|
+
function handleChange(value, selectedOptions) {
|
|
2436
|
+
const result = lodashEs.cloneDeep(selectedOptions);
|
|
2437
|
+
processValue(result);
|
|
2438
|
+
emits("change", result);
|
|
2439
|
+
}
|
|
2440
|
+
function processValue(selectedOptions) {
|
|
2441
|
+
selectedOptions.forEach((item) => {
|
|
2442
|
+
if (Array.isArray(item))
|
|
2443
|
+
processValue(item);
|
|
2444
|
+
else {
|
|
2445
|
+
delete item.disabled;
|
|
2446
|
+
delete item.children;
|
|
2447
|
+
delete item.isLeaf;
|
|
2448
|
+
delete item.loading;
|
|
2449
|
+
}
|
|
2450
|
+
});
|
|
2451
|
+
}
|
|
2452
|
+
function formatValue(value) {
|
|
2453
|
+
value = value || [];
|
|
2454
|
+
return value.reduce((pre, cur) => {
|
|
2455
|
+
if (Array.isArray(cur)) {
|
|
2456
|
+
pre.push(cur.map((c) => c.value));
|
|
2457
|
+
} else {
|
|
2458
|
+
pre.push(cur.value);
|
|
2459
|
+
}
|
|
2460
|
+
return pre;
|
|
2461
|
+
}, []);
|
|
2412
2462
|
}
|
|
2413
2463
|
initOptions();
|
|
2414
2464
|
return (_ctx, _cache) => {
|
|
2415
2465
|
return vue.openBlock(), vue.createBlock(vue.unref(antDesignVue.Cascader), {
|
|
2416
|
-
value: __props.value,
|
|
2466
|
+
value: formatValue(__props.value),
|
|
2417
2467
|
placeholder: "\u8BF7\u8F93\u5165",
|
|
2418
2468
|
multiple: __props.multiple,
|
|
2419
2469
|
options: options.value,
|
|
2420
2470
|
"load-data": loadData,
|
|
2421
2471
|
"get-popup-container": vue.unref(getContainer),
|
|
2422
|
-
|
|
2472
|
+
onChange: handleChange
|
|
2423
2473
|
}, null, 8, ["value", "multiple", "options", "get-popup-container"]);
|
|
2424
2474
|
};
|
|
2425
2475
|
}
|
|
2426
2476
|
});
|
|
2427
|
-
var
|
|
2477
|
+
var materialType$1 = /* @__PURE__ */ _export_sfc(_sfc_main$3, [["__file", "material-type.vue"]]);
|
|
2428
2478
|
|
|
2429
|
-
FC__default["default"].register({
|
|
2430
|
-
name: 'materialTypesOption',
|
|
2431
|
-
init({ value }, rule) {
|
|
2432
|
-
getOption(value, { level: 1, relationCode: '' }).then((data) => {
|
|
2433
|
-
data = isLeaf(data, rule.config.format === 1);
|
|
2434
|
-
if (rule.props) {
|
|
2435
|
-
rule.props.options = data;
|
|
2436
|
-
}
|
|
2437
|
-
else {
|
|
2438
|
-
(rule.props = {}).options = data;
|
|
2439
|
-
}
|
|
2440
|
-
});
|
|
2441
|
-
},
|
|
2442
|
-
});
|
|
2443
|
-
function getOption(config, data) {
|
|
2444
|
-
return config.fetch(data);
|
|
2445
|
-
}
|
|
2446
|
-
function isLeaf(data, value) {
|
|
2447
|
-
data.forEach((item) => {
|
|
2448
|
-
item.isLeaf = value;
|
|
2449
|
-
});
|
|
2450
|
-
return data;
|
|
2451
|
-
}
|
|
2452
2479
|
var materialType = {
|
|
2453
2480
|
name: 'materialType',
|
|
2454
2481
|
rule(data, extraConfig) {
|
|
2455
2482
|
return {
|
|
2456
|
-
type: '
|
|
2483
|
+
type: 'materialType',
|
|
2484
|
+
component: materialType$1,
|
|
2457
2485
|
field: data.field,
|
|
2458
2486
|
title: '素材类型',
|
|
2459
2487
|
validate: [
|
|
@@ -2465,38 +2493,22 @@ var materialType = {
|
|
|
2465
2493
|
},
|
|
2466
2494
|
],
|
|
2467
2495
|
props: {
|
|
2468
|
-
|
|
2496
|
+
value: data.value,
|
|
2469
2497
|
multiple: data.props.multiple,
|
|
2470
|
-
loadData(inject, selectedOptions) {
|
|
2471
|
-
const optionLength = selectedOptions.length;
|
|
2472
|
-
const targetOption = selectedOptions[optionLength - 1];
|
|
2473
|
-
targetOption.loading = true;
|
|
2474
|
-
getOption(extraConfig.materialType, {
|
|
2475
|
-
level: optionLength + 1,
|
|
2476
|
-
relationCode: targetOption.value,
|
|
2477
|
-
})
|
|
2478
|
-
.then((result) => {
|
|
2479
|
-
result = isLeaf(result, inject.self.config.format === optionLength + 1);
|
|
2480
|
-
targetOption.children = result;
|
|
2481
|
-
})
|
|
2482
|
-
.finally(() => {
|
|
2483
|
-
targetOption.loading = false;
|
|
2484
|
-
});
|
|
2485
|
-
},
|
|
2486
|
-
},
|
|
2487
|
-
config: {
|
|
2488
2498
|
format: data.config.format,
|
|
2489
|
-
|
|
2490
|
-
|
|
2491
|
-
materialTypesOption: extraConfig.materialType,
|
|
2499
|
+
config: extraConfig.materialType,
|
|
2500
|
+
disabled: data.disabled,
|
|
2492
2501
|
},
|
|
2493
2502
|
inject: true,
|
|
2494
2503
|
on: {
|
|
2495
2504
|
change(inject, list) {
|
|
2496
2505
|
const rule = inject.self;
|
|
2497
2506
|
rule.value = list;
|
|
2507
|
+
rule.props.value = list;
|
|
2498
2508
|
vue.nextTick(() => {
|
|
2499
|
-
|
|
2509
|
+
setTimeout(() => {
|
|
2510
|
+
inject.api.validateField(rule.field);
|
|
2511
|
+
});
|
|
2500
2512
|
});
|
|
2501
2513
|
},
|
|
2502
2514
|
},
|
|
@@ -2505,7 +2517,8 @@ var materialType = {
|
|
|
2505
2517
|
},
|
|
2506
2518
|
rowRule(data, extraConfig) {
|
|
2507
2519
|
return {
|
|
2508
|
-
type: '
|
|
2520
|
+
type: 'materialType',
|
|
2521
|
+
component: materialType$1,
|
|
2509
2522
|
field: data.field,
|
|
2510
2523
|
title: '素材类型',
|
|
2511
2524
|
validate: [
|
|
@@ -2517,35 +2530,22 @@ var materialType = {
|
|
|
2517
2530
|
},
|
|
2518
2531
|
],
|
|
2519
2532
|
props: {
|
|
2520
|
-
|
|
2533
|
+
value: data.value,
|
|
2521
2534
|
multiple: data.props.multiple,
|
|
2522
|
-
loadData(inject, selectedOptions) {
|
|
2523
|
-
const optionLength = selectedOptions.length;
|
|
2524
|
-
const targetOption = selectedOptions[optionLength - 1];
|
|
2525
|
-
targetOption.loading = true;
|
|
2526
|
-
getOption(extraConfig.materialType, optionLength + 1)
|
|
2527
|
-
.then((result) => {
|
|
2528
|
-
result = isLeaf(result, inject.self.config.format === optionLength + 1);
|
|
2529
|
-
targetOption.children = result;
|
|
2530
|
-
})
|
|
2531
|
-
.finally(() => {
|
|
2532
|
-
targetOption.loading = false;
|
|
2533
|
-
});
|
|
2534
|
-
},
|
|
2535
|
-
},
|
|
2536
|
-
config: {
|
|
2537
2535
|
format: data.config.format,
|
|
2538
|
-
|
|
2539
|
-
|
|
2540
|
-
materialTypesOption: extraConfig.materialType,
|
|
2536
|
+
config: extraConfig.materialType,
|
|
2537
|
+
disabled: data.disabled,
|
|
2541
2538
|
},
|
|
2542
2539
|
inject: true,
|
|
2543
2540
|
on: {
|
|
2544
2541
|
change(inject, list) {
|
|
2545
2542
|
const rule = inject.self;
|
|
2546
2543
|
rule.value = list;
|
|
2544
|
+
rule.props.value = list;
|
|
2547
2545
|
vue.nextTick(() => {
|
|
2548
|
-
|
|
2546
|
+
setTimeout(() => {
|
|
2547
|
+
inject.api.validateField(rule.field);
|
|
2548
|
+
});
|
|
2549
2549
|
});
|
|
2550
2550
|
},
|
|
2551
2551
|
},
|
|
@@ -2564,7 +2564,7 @@ var materialType = {
|
|
|
2564
2564
|
minWidth: '138px',
|
|
2565
2565
|
slots: {
|
|
2566
2566
|
default({ row }) {
|
|
2567
|
-
return vue.h(
|
|
2567
|
+
return vue.h(materialType$1, {
|
|
2568
2568
|
multiple: data.props.multiple,
|
|
2569
2569
|
format: data.config.format,
|
|
2570
2570
|
config: extraConfig.materialType,
|
|
@@ -2614,6 +2614,7 @@ var row = {
|
|
|
2614
2614
|
var department = {
|
|
2615
2615
|
name: 'department',
|
|
2616
2616
|
rule(data, extraConfig) {
|
|
2617
|
+
var _a;
|
|
2617
2618
|
return {
|
|
2618
2619
|
type: 'StaffSelector',
|
|
2619
2620
|
component: StaffSelector,
|
|
@@ -2631,6 +2632,7 @@ var department = {
|
|
|
2631
2632
|
return yield extraConfig.department.fetch();
|
|
2632
2633
|
});
|
|
2633
2634
|
},
|
|
2635
|
+
fieldNames: (_a = extraConfig.people) === null || _a === void 0 ? void 0 : _a.fieldNames,
|
|
2634
2636
|
},
|
|
2635
2637
|
effect: {
|
|
2636
2638
|
required: data.effect.required && '请选择',
|
|
@@ -2655,6 +2657,7 @@ var department = {
|
|
|
2655
2657
|
};
|
|
2656
2658
|
},
|
|
2657
2659
|
rowRule(data, extraConfig) {
|
|
2660
|
+
var _a;
|
|
2658
2661
|
return {
|
|
2659
2662
|
type: 'StaffSelector',
|
|
2660
2663
|
component: StaffSelector,
|
|
@@ -2672,6 +2675,7 @@ var department = {
|
|
|
2672
2675
|
return yield extraConfig.department.fetch();
|
|
2673
2676
|
});
|
|
2674
2677
|
},
|
|
2678
|
+
fieldNames: (_a = extraConfig.people) === null || _a === void 0 ? void 0 : _a.fieldNames,
|
|
2675
2679
|
},
|
|
2676
2680
|
effect: {
|
|
2677
2681
|
required: data.effect.required && '请选择',
|