bri-components 1.2.56 → 1.2.57
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/package.json +1 -1
- package/src/components/controls/base/DshCascader/DshCascader.vue +1 -0
- package/src/components/controls/base/DshCascader/cascaderMixin.js +4 -2
- package/src/components/controls/base/DshCascader/cascaderModal.vue +2 -1
- package/src/components/controls/base/DshCascader/cascaderPicker.vue +3 -3
- package/src/components/controls/senior/flatTable.vue +10 -5
- package/src/components/controls/senior/flatTableImportModal.vue +7 -36
package/package.json
CHANGED
|
@@ -17,7 +17,6 @@ export default {
|
|
|
17
17
|
_showMode: "default",
|
|
18
18
|
_filterable: true,
|
|
19
19
|
_cascaderFilterVals: [], // 过滤级联数据,只保留的数组
|
|
20
|
-
_changeOnSelect: false, // 每级菜单都可取值
|
|
21
20
|
_renderFormat: (labels) => labels.join(_joinSymbol),
|
|
22
21
|
|
|
23
22
|
...this.propsObj,
|
|
@@ -26,6 +25,9 @@ export default {
|
|
|
26
25
|
_saveKey: this.propsObj._saveKey || "_key",
|
|
27
26
|
_valueKey: this.propsObj._valueKey || "code",
|
|
28
27
|
_nameKey: this.propsObj._nameKey || "name",
|
|
28
|
+
_changeOnSelect: this.isOnSearch
|
|
29
|
+
? true
|
|
30
|
+
: this.propsObj._changeOnSelect == undefined ? false : this.propsObj._changeOnSelect, // 每级菜单都可取值 -默认取末级
|
|
29
31
|
_joinSymbol: _joinSymbol // 级联拼接符
|
|
30
32
|
};
|
|
31
33
|
},
|
|
@@ -42,7 +44,7 @@ export default {
|
|
|
42
44
|
return this.selfPropsObj._cascaderFilterVals;
|
|
43
45
|
},
|
|
44
46
|
changeOnSelect () {
|
|
45
|
-
return this.
|
|
47
|
+
return this.selfPropsObj._changeOnSelect;
|
|
46
48
|
},
|
|
47
49
|
saveKey () {
|
|
48
50
|
return this.selfPropsObj._saveKey;
|
|
@@ -7,11 +7,11 @@
|
|
|
7
7
|
:visible="showModal"
|
|
8
8
|
:placement="placement"
|
|
9
9
|
:transfer="true"
|
|
10
|
-
transfer-class-name="cascaderPicker-down"
|
|
10
|
+
:transfer-class-name="`cascaderPicker-down ${selfPropsObj._transferClassName}`"
|
|
11
11
|
:stop-propagation="true"
|
|
12
12
|
:events-enabled="true"
|
|
13
13
|
>
|
|
14
|
-
<div @click
|
|
14
|
+
<div @click="clickInput">
|
|
15
15
|
<slot>
|
|
16
16
|
<Input
|
|
17
17
|
v-model="inputStr"
|
|
@@ -24,7 +24,7 @@
|
|
|
24
24
|
</slot>
|
|
25
25
|
</div>
|
|
26
26
|
|
|
27
|
-
<!-- 下拉面板 -->
|
|
27
|
+
<!-- 下拉面板 click.stop目的:slot插槽里的会渲染到body下,点击此面板时,click事件会被Dropdown捕捉到,被当成外部点击事件,用stop阻止住 -->
|
|
28
28
|
<div
|
|
29
29
|
slot="list"
|
|
30
30
|
class="wrap"
|
|
@@ -82,6 +82,7 @@
|
|
|
82
82
|
:propsObj="propsObj"
|
|
83
83
|
:importParams="importParams"
|
|
84
84
|
@input="toggleBatchImportModal"
|
|
85
|
+
@importCb="importCb"
|
|
85
86
|
></flat-table-import-modal>
|
|
86
87
|
</div>
|
|
87
88
|
</template>
|
|
@@ -166,9 +167,9 @@
|
|
|
166
167
|
if (this.propsObj._isExport) {
|
|
167
168
|
btnList.unshift("canExport");
|
|
168
169
|
}
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
170
|
+
if (this.propsObj._isImport && this.finalCanEdit) {
|
|
171
|
+
btnList.unshift("canImport");
|
|
172
|
+
}
|
|
172
173
|
|
|
173
174
|
return btnList;
|
|
174
175
|
},
|
|
@@ -185,10 +186,10 @@
|
|
|
185
186
|
created () {},
|
|
186
187
|
methods: {
|
|
187
188
|
clickBatchImport () {
|
|
188
|
-
|
|
189
|
+
this.openBatchImportModal();
|
|
189
190
|
},
|
|
190
191
|
openBatchImportModal () {
|
|
191
|
-
|
|
192
|
+
this.showBatchImportModal = true;
|
|
192
193
|
},
|
|
193
194
|
// 关闭批量导入模态框
|
|
194
195
|
closeBatchImportModal () {
|
|
@@ -249,6 +250,10 @@
|
|
|
249
250
|
}
|
|
250
251
|
});
|
|
251
252
|
},
|
|
253
|
+
// 回调- 导入成功
|
|
254
|
+
importCb (data) {
|
|
255
|
+
this.value[this.controlKey] = data;
|
|
256
|
+
},
|
|
252
257
|
|
|
253
258
|
// 校验方法 -供外部使用
|
|
254
259
|
validate () {
|
|
@@ -187,7 +187,11 @@
|
|
|
187
187
|
headers: { "Content-Type": "multipart/form-data" }
|
|
188
188
|
},
|
|
189
189
|
callback: data => {
|
|
190
|
-
this.
|
|
190
|
+
this.$Message.success("导入成功");
|
|
191
|
+
this.file = null;
|
|
192
|
+
this.loadingStatus = false;
|
|
193
|
+
this.$emit("importCb", data);
|
|
194
|
+
this.showModal = false;
|
|
191
195
|
},
|
|
192
196
|
error: data => {
|
|
193
197
|
this.$Message.error("导入失败:" + data.msg);
|
|
@@ -198,14 +202,10 @@
|
|
|
198
202
|
});
|
|
199
203
|
},
|
|
200
204
|
|
|
201
|
-
getTransitStatus (id
|
|
205
|
+
getTransitStatus (id) {
|
|
202
206
|
let that = this;
|
|
203
207
|
return function () {
|
|
204
|
-
|
|
205
|
-
that.getImportJobStatus(id);
|
|
206
|
-
} else {
|
|
207
|
-
that.getJobStatus(id);
|
|
208
|
-
}
|
|
208
|
+
that.getJobStatus(id);
|
|
209
209
|
};
|
|
210
210
|
},
|
|
211
211
|
// 状态查询
|
|
@@ -231,35 +231,6 @@
|
|
|
231
231
|
this.timer = null;
|
|
232
232
|
}
|
|
233
233
|
});
|
|
234
|
-
},
|
|
235
|
-
// 导入状态查询
|
|
236
|
-
getImportJobStatus (id) {
|
|
237
|
-
this.$https({
|
|
238
|
-
url: {
|
|
239
|
-
module: "sheet",
|
|
240
|
-
name: "getImportJobStatus"
|
|
241
|
-
},
|
|
242
|
-
params: {
|
|
243
|
-
jobId: id
|
|
244
|
-
},
|
|
245
|
-
callback: data => {
|
|
246
|
-
if (data.status === "over") {
|
|
247
|
-
clearInterval(this.timer);
|
|
248
|
-
this.$Message.success("导入成功");
|
|
249
|
-
this.file = null;
|
|
250
|
-
this.loadingStatus = false;
|
|
251
|
-
this.showModal = false;
|
|
252
|
-
this.$emit("importCb");
|
|
253
|
-
} else if (data.status === "check-fai" || data.status === "fai") {
|
|
254
|
-
clearInterval(this.timer);
|
|
255
|
-
this.$Message.info({ content: data.faiMsg });
|
|
256
|
-
this.loadingStatus = false;
|
|
257
|
-
}
|
|
258
|
-
},
|
|
259
|
-
error: data => {
|
|
260
|
-
this.timer = null;
|
|
261
|
-
}
|
|
262
|
-
});
|
|
263
234
|
}
|
|
264
235
|
}
|
|
265
236
|
};
|