resolver-egretimp-plus 0.0.259 → 0.0.261
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
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import rulesDriver from "../../rules/rulesDriver"
|
|
2
2
|
import { penddingRules } from "../../rules/ruleUtils"
|
|
3
|
-
import { hasOwn, isPlainObject } from "../../utils"
|
|
3
|
+
import { hasOwn, isPlainObject, isPromise } from "../../utils"
|
|
4
4
|
import { resultToast } from "../../utils/respone"
|
|
5
5
|
|
|
6
6
|
export async function executeLoadServices(services = [], {
|
|
@@ -52,7 +52,6 @@ export async function executeLoadServices(services = [], {
|
|
|
52
52
|
reqConfig.params = reqResult
|
|
53
53
|
delete reqConfig.data
|
|
54
54
|
}
|
|
55
|
-
|
|
56
55
|
if (loadEventsBefore && typeof loadEventsBefore === 'function') {
|
|
57
56
|
let beforeRequestRet = true
|
|
58
57
|
if (loadEventsBefore) {
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
<template>
|
|
2
|
+
<!-- <ElText v-bind="{...attrs, ...elTextProps}">{{ labelDesc }}</ElText> -->
|
|
2
3
|
<renderNode></renderNode>
|
|
3
4
|
</template>
|
|
4
5
|
<script setup>
|
|
@@ -22,14 +23,20 @@ const props = defineProps({
|
|
|
22
23
|
const attrs = useAttrs()
|
|
23
24
|
|
|
24
25
|
const normalVal = computed(() => {
|
|
25
|
-
|
|
26
|
+
let val = (modelValue.value !== null && modelValue.value !== undefined) ? modelValue.value : ''
|
|
27
|
+
try {
|
|
28
|
+
val = JSON.stringify(val)
|
|
29
|
+
} catch (error) {
|
|
30
|
+
val = ''
|
|
31
|
+
}
|
|
32
|
+
const findItem = props?.options?.find(item => item.columnValue == val)
|
|
26
33
|
if (findItem) {
|
|
27
34
|
return lang?.value?.indexOf('zh') > -1 ? findItem.columnDesc_zh : findItem.columnDesc
|
|
28
35
|
}
|
|
29
|
-
return
|
|
36
|
+
return val
|
|
30
37
|
})
|
|
31
38
|
|
|
32
|
-
const
|
|
39
|
+
const elTextProps = computed(() => {
|
|
33
40
|
const result = Object.keys(ElText.props).reduce((ret, key) => {
|
|
34
41
|
ret[key] = props[key]
|
|
35
42
|
return ret
|
|
@@ -44,7 +51,7 @@ const labelDesc = computed(() => {
|
|
|
44
51
|
const renderNode = computed(() => {
|
|
45
52
|
const textNode = h(ElText, {
|
|
46
53
|
...attrs,
|
|
47
|
-
...
|
|
54
|
+
...elTextProps.value,
|
|
48
55
|
onClick: () => {
|
|
49
56
|
clickAction()
|
|
50
57
|
}
|
package/src/index.jsx
CHANGED
|
@@ -204,7 +204,7 @@ export default {
|
|
|
204
204
|
reqConfig,
|
|
205
205
|
}) => {
|
|
206
206
|
if (props.loadEventsBefore && typeof props.loadEventsBefore === 'function') {
|
|
207
|
-
return props.
|
|
207
|
+
return props.loadEventsBefore({reqConfig})
|
|
208
208
|
}
|
|
209
209
|
},
|
|
210
210
|
respCb: (result) => {
|