vue2-client 1.9.107 → 1.9.108
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
CHANGED
|
@@ -335,8 +335,8 @@ export default {
|
|
|
335
335
|
getRealKeyData,
|
|
336
336
|
getConfigByNameAsync,
|
|
337
337
|
getConfigByName,
|
|
338
|
-
customEvent (func) {
|
|
339
|
-
this.$emit(func)
|
|
338
|
+
customEvent (func, data) {
|
|
339
|
+
this.$emit(func, data)
|
|
340
340
|
},
|
|
341
341
|
columnClick (key, value, record) {
|
|
342
342
|
this.$emit('columnClick', key, value, record)
|
|
@@ -4,12 +4,12 @@
|
|
|
4
4
|
<a-col v-show="showLeftOperaBtn">
|
|
5
5
|
<span :style="{ float: 'left', overflow: 'hidden', marginBottom: '8px' }">
|
|
6
6
|
<a-space>
|
|
7
|
-
<a-button v-if="eventState.customDelete" type="primary" @click="custom('customDelete')"
|
|
8
|
-
<a-icon type="delete"
|
|
9
|
-
</a-button
|
|
10
|
-
<a-button v-if="eventState.customSave" type="primary" @click="custom('customSave')"
|
|
11
|
-
<a-icon type="save"
|
|
12
|
-
</a-button
|
|
7
|
+
<!-- <a-button v-if="eventState.customDelete" type="primary" @click="custom('customDelete')">-->
|
|
8
|
+
<!-- <a-icon type="delete"/>删除-->
|
|
9
|
+
<!-- </a-button>-->
|
|
10
|
+
<!-- <a-button v-if="eventState.customSave" type="primary" @click="custom('customSave')">-->
|
|
11
|
+
<!-- <a-icon type="save"/>保存-->
|
|
12
|
+
<!-- </a-button>-->
|
|
13
13
|
<slot name="leftButton" :selectedRowKeys="selectedRowKeys" :selectedRows="selectedRows"></slot>
|
|
14
14
|
<a-button v-if="buttonState.add && buttonRendering('add')" type="primary" @click="add">
|
|
15
15
|
<a-icon type="plus"/>新增
|
|
@@ -553,6 +553,13 @@ export default {
|
|
|
553
553
|
// 获取最新数据
|
|
554
554
|
const editRowAfterData = this.getTableData()
|
|
555
555
|
const changeData = getChangedData(this.editRowBeforeData, editRowAfterData)
|
|
556
|
+
if (this.eventState?.customSave) {
|
|
557
|
+
this.custom('customSave', {
|
|
558
|
+
tableData: editRowAfterData,
|
|
559
|
+
changeData
|
|
560
|
+
})
|
|
561
|
+
return
|
|
562
|
+
}
|
|
556
563
|
if (changeData.length === 0) {
|
|
557
564
|
this.$message.info('没有数据发生变化')
|
|
558
565
|
} else {
|
|
@@ -1034,6 +1041,10 @@ export default {
|
|
|
1034
1041
|
},
|
|
1035
1042
|
// 新增业务
|
|
1036
1043
|
add () {
|
|
1044
|
+
if (this.eventState?.customAdd) {
|
|
1045
|
+
this.custom('customAdd', {})
|
|
1046
|
+
return
|
|
1047
|
+
}
|
|
1037
1048
|
this.$emit('add')
|
|
1038
1049
|
},
|
|
1039
1050
|
// 添加业务
|
|
@@ -1048,6 +1059,10 @@ export default {
|
|
|
1048
1059
|
edit (id) {
|
|
1049
1060
|
this.editLoading = true
|
|
1050
1061
|
this.getEditData(id).then(modifyModelData => {
|
|
1062
|
+
if (this.eventState?.customEdit) {
|
|
1063
|
+
this.custom('customEdit', { id, modifyModelData })
|
|
1064
|
+
return
|
|
1065
|
+
}
|
|
1051
1066
|
this.$emit('edit', modifyModelData)
|
|
1052
1067
|
this.editLoading = false
|
|
1053
1068
|
})
|
|
@@ -1116,6 +1131,13 @@ export default {
|
|
|
1116
1131
|
queryParamsName: this.queryParamsName,
|
|
1117
1132
|
idList: this.selectedRowKeys
|
|
1118
1133
|
}
|
|
1134
|
+
if (this.eventState?.customDelete) {
|
|
1135
|
+
this.custom('customDelete', {
|
|
1136
|
+
selectedRowKeys: this.selectedRowKeys,
|
|
1137
|
+
selectedRows: this.selectedRows
|
|
1138
|
+
})
|
|
1139
|
+
return
|
|
1140
|
+
}
|
|
1119
1141
|
return new Promise((resolve, reject) => {
|
|
1120
1142
|
if (this.localEditMode) {
|
|
1121
1143
|
this.localEditModeDataSource = this.getLocalData().filter(item => !this.selectedRowKeys.includes(item[this.rowKey]))
|
|
@@ -87,9 +87,9 @@ routerResource.example = {
|
|
|
87
87
|
// component: () => import('@vue2-client/base-client/components/common/XFormGroup/demo.vue'),
|
|
88
88
|
// component: () => import('@vue2-client/base-client/components/common/XFormGroup/demo.vue'),
|
|
89
89
|
// component: () => import('@vue2-client/base-client/components/common/XReport/XReportDemo.vue'),
|
|
90
|
-
component: () => import('@vue2-client/base-client/components/common/XFormTable/demo.vue'),
|
|
90
|
+
// component: () => import('@vue2-client/base-client/components/common/XFormTable/demo.vue'),
|
|
91
91
|
// component: () => import('@vue2-client/base-client/components/common/XTab/XTabDemo.vue'),
|
|
92
|
-
|
|
92
|
+
component: () => import('@vue2-client/base-client/components/common/XReportGrid/XReportDemo.vue'),
|
|
93
93
|
// component: () => import('@vue2-client/pages/WorkflowDetail/WorkFlowDemo.vue'),
|
|
94
94
|
// component: () => import('@vue2-client/base-client/components/common/XConversation/XConversationDemo.vue'),
|
|
95
95
|
// component: () => import('@vue2-client/base-client/components/common/XButtons/XButtonDemo.vue'),
|