vue2-client 1.9.6 → 1.9.8
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/base-client/components/common/XAddNativeForm/XAddNativeForm.vue +4 -1
- package/src/base-client/components/common/XFormTable/XFormTable.vue +4 -1
- package/src/base-client/components/common/XTab/XTab.vue +3 -3
- package/src/base-client/components/common/XTable/XTable.vue +1 -1
package/package.json
CHANGED
|
@@ -86,7 +86,7 @@
|
|
|
86
86
|
import XFormItem from '@vue2-client/base-client/components/common/XForm/XFormItem'
|
|
87
87
|
import { formatDate } from '@vue2-client/utils/util'
|
|
88
88
|
import { mapState } from 'vuex'
|
|
89
|
-
import { addOrModify, runLogic } from '@vue2-client/services/api/common'
|
|
89
|
+
import { addOrModify, getConfigByName, getConfigByNameAsync, runLogic } from '@vue2-client/services/api/common'
|
|
90
90
|
import { checkIdNumber, REG_EMAIL, REG_LANDLINE, REG_PHONE } from '@vue2-client/utils/reg'
|
|
91
91
|
import moment from 'moment/moment'
|
|
92
92
|
import { executeStrFunction } from '@vue2-client/utils/runEvalFunction'
|
|
@@ -199,6 +199,9 @@ export default {
|
|
|
199
199
|
...mapState('account', { currUser: 'user' })
|
|
200
200
|
},
|
|
201
201
|
methods: {
|
|
202
|
+
runLogic,
|
|
203
|
+
getConfigByNameAsync,
|
|
204
|
+
getConfigByName,
|
|
202
205
|
init (params) {
|
|
203
206
|
const {
|
|
204
207
|
configName, configContent, formItems, formJson, viewMode, isHandleFormKey = true,
|
|
@@ -118,7 +118,7 @@ import XImportExcel from '@vue2-client/base-client/components/common/XImportExce
|
|
|
118
118
|
import {
|
|
119
119
|
getConfigByName,
|
|
120
120
|
getConfigByLogic,
|
|
121
|
-
parseConfig,
|
|
121
|
+
parseConfig, runLogic, getConfigByNameAsync,
|
|
122
122
|
} from '@vue2-client/services/api/common'
|
|
123
123
|
import { mapState } from 'vuex'
|
|
124
124
|
import XTreePro from '@vue2-client/base-client/components/common/XTree/XTreePro.vue'
|
|
@@ -301,6 +301,9 @@ export default {
|
|
|
301
301
|
this.initConfig()
|
|
302
302
|
},
|
|
303
303
|
methods: {
|
|
304
|
+
runLogic,
|
|
305
|
+
getConfigByNameAsync,
|
|
306
|
+
getConfigByName,
|
|
304
307
|
importExcelOk () {
|
|
305
308
|
this.$emit('importExcelOk')
|
|
306
309
|
},
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
:serviceName="tab.serviceName"
|
|
15
15
|
:serverName="tab.serviceName"
|
|
16
16
|
:queryParamsName="tab.slotConfig"
|
|
17
|
-
v-on="getEventHandlers(tab)"
|
|
17
|
+
v-on="getEventHandlers(tab,index)"
|
|
18
18
|
@hook:mounted="(h)=>onComponentMounted(h,tab,index)"
|
|
19
19
|
:config-name="tab.slotConfig"
|
|
20
20
|
:env="env"
|
|
@@ -61,7 +61,7 @@ export default {
|
|
|
61
61
|
runLogic,
|
|
62
62
|
getConfigByNameAsync,
|
|
63
63
|
getConfigByName,
|
|
64
|
-
getEventHandlers (tab) {
|
|
64
|
+
getEventHandlers (tab, index) {
|
|
65
65
|
const handlers = {}
|
|
66
66
|
if (!tab?.events || tab?.events?.length === 0) {
|
|
67
67
|
return handlers
|
|
@@ -69,7 +69,7 @@ export default {
|
|
|
69
69
|
tab.events.forEach(event => {
|
|
70
70
|
handlers[event.type] = (...args) => {
|
|
71
71
|
console.info('Event handled:', event.type, args)
|
|
72
|
-
executeStrFunctionByContext(this, event.customFunction, args)
|
|
72
|
+
executeStrFunctionByContext(this.$refs[`tab_com_${tab.slotType}_${index}`][0], event.customFunction, args)
|
|
73
73
|
}
|
|
74
74
|
})
|
|
75
75
|
return handlers
|