meixioacomponent 0.2.68 → 0.2.71
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/lib/meixioacomponent.common.js +216 -191
- package/lib/meixioacomponent.umd.js +216 -191
- package/lib/meixioacomponent.umd.min.js +13 -13
- package/package.json +1 -1
- package/packages/components/proPageTable/oa_pro-table-search.vue +1 -4
- package/packages/components/proPageTable/oa_pro_screen_item.vue +7 -4
- package/packages/components/proPageTable/oa_pro_table.vue +43 -21
package/package.json
CHANGED
|
@@ -184,10 +184,7 @@ export default {
|
|
|
184
184
|
type: "info",
|
|
185
185
|
plain: true,
|
|
186
186
|
click: () => {
|
|
187
|
-
this.$parent.cleanProscreenCondition();
|
|
188
|
-
this.$nextTick(() => {
|
|
189
|
-
this.$parent.refreshData();
|
|
190
|
-
});
|
|
187
|
+
this.$parent.cleanProscreenCondition(true);
|
|
191
188
|
},
|
|
192
189
|
},
|
|
193
190
|
];
|
|
@@ -119,10 +119,13 @@ export default {
|
|
|
119
119
|
|
|
120
120
|
deleteProscreen() {
|
|
121
121
|
const { config } = this.$props;
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
122
|
+
if (config) {
|
|
123
|
+
let index = config.findIndex((configItem) => {
|
|
124
|
+
return configItem.key == this.item.key;
|
|
125
|
+
});
|
|
126
|
+
config[index].isCheck = false;
|
|
127
|
+
}
|
|
128
|
+
|
|
126
129
|
this.$emit("deleteProscreenItem");
|
|
127
130
|
},
|
|
128
131
|
trigerCheck(index, params) {
|
|
@@ -232,6 +232,9 @@ export default {
|
|
|
232
232
|
|
|
233
233
|
// 是否开启表格横向条纹
|
|
234
234
|
borderRow: true,
|
|
235
|
+
|
|
236
|
+
// 倒计时
|
|
237
|
+
triggerDown: null,
|
|
235
238
|
};
|
|
236
239
|
},
|
|
237
240
|
created() {
|
|
@@ -243,6 +246,7 @@ export default {
|
|
|
243
246
|
},
|
|
244
247
|
beforeDestroy() {
|
|
245
248
|
componentConfig.eventBus.$off("handleTableBorder", this.handleTableBorder);
|
|
249
|
+
clearTimeout(this.triggerDown);
|
|
246
250
|
},
|
|
247
251
|
computed: {
|
|
248
252
|
config() {
|
|
@@ -448,7 +452,8 @@ export default {
|
|
|
448
452
|
cellMouseEnter(row, column, cell, event) {
|
|
449
453
|
let content = row[`${column.property}`];
|
|
450
454
|
this.tooltip.show = false;
|
|
451
|
-
if (
|
|
455
|
+
if (typeof content == Boolean || typeof content == Object || !content)
|
|
456
|
+
return;
|
|
452
457
|
const { tooltip } = this;
|
|
453
458
|
let style = event.target;
|
|
454
459
|
let position = style.getBoundingClientRect();
|
|
@@ -632,12 +637,14 @@ export default {
|
|
|
632
637
|
if (this.$props.screenList) {
|
|
633
638
|
let _screenListIndexItem =
|
|
634
639
|
this.$props.screenList.list[this.$props.screenList.index];
|
|
635
|
-
result[`keyword`] = this.module;
|
|
636
640
|
result[`${_screenListIndexItem.key}`] = _screenListIndexItem.value;
|
|
637
641
|
}
|
|
638
|
-
|
|
642
|
+
result[`keyword`] = this.module;
|
|
639
643
|
this.proScreenList.forEach((item) => {
|
|
640
|
-
|
|
644
|
+
const { key, value } = item;
|
|
645
|
+
if (typeof value == Number || typeof value == Boolean || value) {
|
|
646
|
+
result[`${key}`] = value;
|
|
647
|
+
}
|
|
641
648
|
});
|
|
642
649
|
result = Object.assign(result, this.$props.pageProps);
|
|
643
650
|
return result;
|
|
@@ -647,6 +654,7 @@ export default {
|
|
|
647
654
|
this.loading = true;
|
|
648
655
|
this.defaultSvg = false;
|
|
649
656
|
this.cleanCheckValue();
|
|
657
|
+
clearTimeout(this.triggerDown);
|
|
650
658
|
if (init) {
|
|
651
659
|
this.$props.pageProps[this.$props.pageConfig.page] = 1;
|
|
652
660
|
}
|
|
@@ -657,19 +665,14 @@ export default {
|
|
|
657
665
|
});
|
|
658
666
|
},
|
|
659
667
|
// 设置表格数据
|
|
660
|
-
setTableData(data) {
|
|
668
|
+
setTableData(data, immediately = true) {
|
|
661
669
|
this.tableData = [];
|
|
662
|
-
|
|
663
|
-
|
|
664
|
-
|
|
665
|
-
|
|
666
|
-
|
|
667
|
-
|
|
668
|
-
this.computedTotalList();
|
|
669
|
-
this.$nextTick(() => {
|
|
670
|
-
this.scrollToTop();
|
|
671
|
-
});
|
|
672
|
-
}, 1000);
|
|
670
|
+
this.tableData = data;
|
|
671
|
+
if (immediately) {
|
|
672
|
+
this.tableDataCompleted();
|
|
673
|
+
} else {
|
|
674
|
+
this.setTriggerDown();
|
|
675
|
+
}
|
|
673
676
|
},
|
|
674
677
|
|
|
675
678
|
// 表格如果有滚动条将滚动条拉到顶部
|
|
@@ -687,11 +690,14 @@ export default {
|
|
|
687
690
|
});
|
|
688
691
|
},
|
|
689
692
|
// 清空高级筛选的条件
|
|
690
|
-
cleanProscreenCondition() {
|
|
693
|
+
cleanProscreenCondition(flag = false) {
|
|
691
694
|
if (this.proScreenList.length <= 0) return;
|
|
692
695
|
this.proScreenList.forEach((item) => {
|
|
693
696
|
item.value = null;
|
|
694
697
|
});
|
|
698
|
+
if (flag) {
|
|
699
|
+
this.refreshData(true);
|
|
700
|
+
}
|
|
695
701
|
},
|
|
696
702
|
// 自定义表格的列
|
|
697
703
|
setTableHeaderConfig(configList) {
|
|
@@ -708,7 +714,7 @@ export default {
|
|
|
708
714
|
label: "",
|
|
709
715
|
key: "noData",
|
|
710
716
|
lock: false,
|
|
711
|
-
width:
|
|
717
|
+
width: 30,
|
|
712
718
|
show: true,
|
|
713
719
|
template: false,
|
|
714
720
|
});
|
|
@@ -763,10 +769,26 @@ export default {
|
|
|
763
769
|
handleTableBorder(params) {
|
|
764
770
|
this[`${params.key}`] = params.value;
|
|
765
771
|
},
|
|
772
|
+
|
|
773
|
+
setTriggerDown() {
|
|
774
|
+
clearTimeout(this.triggerDown);
|
|
775
|
+
this.triggerDown = setTimeout(() => {
|
|
776
|
+
this.tableDataCompleted();
|
|
777
|
+
}, 1000);
|
|
778
|
+
},
|
|
779
|
+
|
|
780
|
+
tableDataCompleted() {
|
|
781
|
+
if (this.tableData.length == 0) {
|
|
782
|
+
this.defaultSvg = true;
|
|
783
|
+
}
|
|
784
|
+
this.loading = false;
|
|
785
|
+
this.computedTotalList();
|
|
786
|
+
this.$nextTick(() => {
|
|
787
|
+
this.scrollToTop();
|
|
788
|
+
});
|
|
789
|
+
},
|
|
766
790
|
},
|
|
767
|
-
watch: {
|
|
768
|
-
fixedList(newValue, oldValue) {},
|
|
769
|
-
},
|
|
791
|
+
watch: {},
|
|
770
792
|
};
|
|
771
793
|
</script>
|
|
772
794
|
|