resolver-egretimp-plus 0.0.69 → 0.0.70

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
  {
2
2
  "name": "resolver-egretimp-plus",
3
- "version": "0.0.69",
3
+ "version": "0.0.70",
4
4
  "description": "交付体验渲染",
5
5
  "main": "./dist/web/index.js",
6
6
  "module": "./dist/web/index.js",
@@ -48,7 +48,7 @@ export default {
48
48
  delete ret.onClick
49
49
  return ret
50
50
  })
51
- const request_traceId = inject('request_traceId')
51
+ const requestTraceId = inject('requestTraceId')
52
52
  const polyfillConfigs = inject('_polyfillConfigs', {})
53
53
  const buttonActions = inject('buttonActions', {})
54
54
  const route = useRoute()
@@ -185,7 +185,7 @@ export default {
185
185
  attrs?.onClick?.call(context, e) // 如果配置中有点击事件
186
186
  executeEventOrchestration({
187
187
  props,
188
- request_traceId: request_traceId?.value,
188
+ requestTraceId: requestTraceId?.value,
189
189
  axiosInstance: _axiosInstance?.value,
190
190
  polyfillConfigs,
191
191
  rootValue: rootValue?.value,
@@ -4,16 +4,16 @@ import { getRelateConfigKeys } from "../../rules/ruleUtils"
4
4
  import { RESULT_CODE, resultToast } from "../../utils/respone"
5
5
  import { unionWith } from "../../utils/index"
6
6
 
7
- export async function dispatchClickEvents ({serviceList = [], request_traceId, axiosInstance, dynamicMapComp, rootValue, dynamicHireRelat, messageCb, compConfig, messageInstance}) {
7
+ export async function dispatchClickEvents ({serviceList = [], requestTraceId, axiosInstance, dynamicMapComp, rootValue, dynamicHireRelat, messageCb, compConfig, messageInstance}) {
8
8
  const dynamicMapCompKeys = Object.keys(dynamicMapComp)
9
9
  const mixinServiceConfig = serviceList.find(service => service.serviceType === '1')
10
10
  for (let i = 0; i < serviceList.length; i++) {
11
11
  const service = serviceList[i]
12
- dispatchClickEvent(service, {dynamicMapComp, request_traceId, mixinServiceConfig, rootValue, dynamicMapCompKeys, dynamicHireRelat, axiosInstance, messageCb, compConfig, messageInstance})
12
+ dispatchClickEvent(service, {dynamicMapComp, requestTraceId, mixinServiceConfig, rootValue, dynamicMapCompKeys, dynamicHireRelat, axiosInstance, messageCb, compConfig, messageInstance})
13
13
  }
14
14
  }
15
15
 
16
- export async function dispatchClickEvent(service, { dynamicMapComp, request_traceId, mixinServiceConfig, rootValue, dynamicMapCompKeys, dynamicHireRelat, axiosInstance, messageCb, compConfig, messageInstance }) {
16
+ export async function dispatchClickEvent(service, { dynamicMapComp, requestTraceId, mixinServiceConfig, rootValue, dynamicMapCompKeys, dynamicHireRelat, axiosInstance, messageCb, compConfig, messageInstance }) {
17
17
  let reqData = rootValue || {}
18
18
  let tableConfig = null
19
19
  if (service.transactionType == '1') {
@@ -29,9 +29,8 @@ export async function dispatchClickEvent(service, { dynamicMapComp, request_trac
29
29
  url,
30
30
  method: "post",
31
31
  data: {
32
- request_traceId,
32
+ requestTraceId,
33
33
  pmHandleBusinessIdentity: {
34
- request_traceId,
35
34
  busiIdentityId: service.busiIdentityId,
36
35
  pageMetaId: service.pageMetaId,
37
36
  tenantId: service.tenantId,
@@ -234,16 +233,15 @@ export function openDailg({
234
233
  }
235
234
 
236
235
  // 数据校验服务
237
- export async function executeDataValid(validConfig, { dynamicMapComp, request_traceId, mixinServiceConfig, rootValue, axiosInstance, lang}) {
236
+ export async function executeDataValid(validConfig, { dynamicMapComp, requestTraceId, mixinServiceConfig, rootValue, axiosInstance, lang}) {
238
237
  let reqData = rootValue || {}
239
238
  const url = DATA_VALID_RULE_EXECUTE
240
239
  const ret = await (axiosInstance && axiosInstance({
241
240
  url,
242
241
  method: "post",
243
242
  data: {
244
- request_traceId,
243
+ requestTraceId,
245
244
  pmHandleBusinessIdentity: {
246
- request_traceId,
247
245
  busiIdentityId: validConfig.busiIdentityId,
248
246
  pageMetaId: validConfig.pageMetaId,
249
247
  tenantId: validConfig.tenantId,
@@ -307,7 +305,7 @@ function closePage(lcpPageClosedMapVO) {
307
305
  }
308
306
  }
309
307
 
310
- export async function executeEventOrchestration({props, request_traceId, axiosInstance, polyfillConfigs, buttonActions, rootValue, confirmInstance, dynamicMapComp, messageInstance, openChildDialog, messageCb, lang, appContext } = {}) {
308
+ export async function executeEventOrchestration({props, requestTraceId, axiosInstance, polyfillConfigs, buttonActions, rootValue, confirmInstance, dynamicMapComp, messageInstance, openChildDialog, messageCb, lang, appContext } = {}) {
311
309
  const lcpPageRuleVOLis = props.config?.lcpPageRuleVOList || []
312
310
  const PageServiceMapVOList = props.config.lcpPageServiceMapVOList || []
313
311
  const mixinServiceConfig = PageServiceMapVOList.find(service => service.serviceType === '1')
@@ -316,7 +314,7 @@ export async function executeEventOrchestration({props, request_traceId, axiosIn
316
314
  const validConfig = lcpPageRuleVOLis[0]
317
315
  const valid = await executeDataValid(validConfig, {
318
316
  dynamicMapComp,
319
- request_traceId,
317
+ requestTraceId,
320
318
  rootValue,
321
319
  axiosInstance,
322
320
  mixinServiceConfig,
@@ -332,7 +330,7 @@ export async function executeEventOrchestration({props, request_traceId, axiosIn
332
330
  dispatchClickEvents({
333
331
  serviceList: PageServiceMapVOList,
334
332
  axiosInstance,
335
- request_traceId,
333
+ requestTraceId,
336
334
  rootValue,
337
335
  dynamicMapComp,
338
336
  dynamicHireRelat,
@@ -1,6 +1,6 @@
1
1
  import { resultToast } from "../../utils/respone"
2
2
 
3
- export async function executeLoadServices(services = [], { request_traceId, axiosInstance, messageInstance, reqData, respCb }) {
3
+ export async function executeLoadServices(services = [], { requestTraceId, axiosInstance, messageInstance, reqData, respCb }) {
4
4
  if (reqData?.notLoad) {
5
5
  return
6
6
  }
@@ -17,9 +17,8 @@ export async function executeLoadServices(services = [], { request_traceId, axio
17
17
  url,
18
18
  method: "post",
19
19
  data: {
20
- request_traceId,
20
+ requestTraceId,
21
21
  pmHandleBusinessIdentity: {
22
- request_traceId,
23
22
  busiIdentityId: service.busiIdentityId,
24
23
  pageMetaId: service.pageMetaId,
25
24
  tenantId: service.tenantId,
@@ -42,7 +42,7 @@ export function usePageConfig() {
42
42
  }
43
43
  }
44
44
 
45
- export function useBuildInData({ messageInstance, loadingInstance, request_traceId }) {
45
+ export function useBuildInData({ messageInstance, loadingInstance, requestTraceId }) {
46
46
  const pageConfig = ref(null)
47
47
  function getPageConfig(reqData, cb) {
48
48
  if (loadingInstance.start && typeof loadingInstance.start === 'function') {
@@ -50,7 +50,7 @@ export function useBuildInData({ messageInstance, loadingInstance, request_trace
50
50
  } else if (loadingInstance.show && typeof loadingInstance.show === 'function') {
51
51
  loadingInstance.show()
52
52
  }
53
- buildInRequest(QUERY_PAGE_CONFIG_DATA, {...reqData, request_traceId}).then(ret => {
53
+ buildInRequest(QUERY_PAGE_CONFIG_DATA, {...reqData, requestTraceId}).then(ret => {
54
54
  if (resultToast(ret.data, messageInstance, { noSuccessIip: true })) {
55
55
  // pageConfig.value = normalPageConfigs(mock)
56
56
  pageConfig.value = normalPageConfigs(ret.data.result)
package/src/index.jsx CHANGED
@@ -112,7 +112,7 @@ export default {
112
112
  },
113
113
  // 提示语的回调
114
114
  messageCb: Function,
115
- request_traceId: {
115
+ requestTraceId: {
116
116
  type: String,
117
117
  }
118
118
  },
@@ -157,7 +157,7 @@ export default {
157
157
  executeLoadServices(
158
158
  props.config?.pmPageServiceMapVOList || props.config?.lcpPageServiceMapVOList || [],
159
159
  {
160
- request_traceId: props.request_traceId,
160
+ requestTraceId: props.requestTraceId,
161
161
  messageInstance: toRef(props, 'messageInstance'),
162
162
  axiosInstance,
163
163
  reqData: props.loadEvnetsReq,
@@ -185,7 +185,7 @@ export default {
185
185
  executeLoadServices(
186
186
  props.config?.pmPageServiceMapVOList || [],
187
187
  {
188
- request_traceId: props.request_traceId,
188
+ requestTraceId: props.requestTraceId,
189
189
  messageInstance: toRef(props, 'messageInstance'),
190
190
  axiosInstance,
191
191
  reqData: props.loadEvnetsReq,
@@ -223,7 +223,7 @@ export default {
223
223
  provide('_parentRootValue', props.parentRootValue)
224
224
  provide('_selectionsObj', props.selectionsObj)
225
225
  provide('_polyfillConfigs', props.polyfillConfigs)
226
- provide('request_traceId', toRef(props, 'request_traceId')) // 所有渲染器调用的接口,都需要加次参数(生哥提)
226
+ provide('requestTraceId', toRef(props, 'requestTraceId')) // 所有渲染器调用的接口,都需要加次参数(生哥提)
227
227
 
228
228
  const rootForm = ref(null)
229
229
  provide('rootForm', rootForm)
@@ -30,7 +30,7 @@ const props = defineProps({
30
30
  return () => {}
31
31
  }
32
32
  },
33
- request_traceId: {
33
+ requestTraceId: {
34
34
  type: String,
35
35
  default: generateUniqueId()
36
36
  }
@@ -72,6 +72,6 @@ defineExpose({
72
72
  :confirmInstance="props.confirmInstance"
73
73
  :openChildDialogInstance="props.openChildDialogInstance"
74
74
  :loadingInstance="props.loadingInstance"
75
- :request_traceId="props.request_traceId"
75
+ :requestTraceId="props.requestTraceId"
76
76
  ></Resolver>
77
77
  </template>
@@ -22,7 +22,7 @@ const props = defineProps({
22
22
  type: [Object, Function],
23
23
  default: () => null
24
24
  },
25
- request_traceId: {
25
+ requestTraceId: {
26
26
  type: String,
27
27
  }
28
28
  })
@@ -31,7 +31,7 @@ defineOptions({
31
31
  })
32
32
  const attrs = useAttrs()
33
33
  initInterceptors(props.messageInstance)
34
- const { getPageConfig, pageConfig, selects } = useBuildInData({messageInstance: props.messageInstance, loadingInstance: props.loadingInstance, request_traceId: props.request_traceId})
34
+ const { getPageConfig, pageConfig, selects } = useBuildInData({messageInstance: props.messageInstance, loadingInstance: props.loadingInstance, requestTraceId: props.requestTraceId})
35
35
  getPageConfig({
36
36
  busiIdentityId: props.busiIdentityId,
37
37
  queryPageMeta: '1',
@@ -78,6 +78,6 @@ defineExpose({
78
78
  :getNativeComps="props.getNativeComps"
79
79
  :config="pageConfig || null"
80
80
  :selects="allSelects"
81
- :request_traceId="props.request_traceId"
81
+ :requestTraceId="props.requestTraceId"
82
82
  ></Resolver>
83
83
  </template>
@@ -29,7 +29,7 @@ const props = defineProps({
29
29
  return openChildDialog
30
30
  }
31
31
  },
32
- request_traceId: {
32
+ requestTraceId: {
33
33
  type: String,
34
34
  default: generateUniqueId()
35
35
  }
@@ -71,6 +71,6 @@ defineExpose({
71
71
  :confirmInstance="props.confirmInstance"
72
72
  :openChildDialogInstance="props.openChildDialogInstance"
73
73
  :loadingInstance="props.loadingInstance"
74
- :request_traceId="props.request_traceId"
74
+ :requestTraceId="props.requestTraceId"
75
75
  ></Resolver>
76
76
  </template>
@@ -5,7 +5,7 @@
5
5
  & > .CustomComponentRow {
6
6
  & > div {
7
7
  margin-right: 16px;
8
- margin-bottom: 16px;
8
+ // margin-bottom: 16px;
9
9
  }
10
10
  }
11
11
  }
@@ -227,7 +227,7 @@ export function getDate(...arg) {
227
227
  }
228
228
  // 生成唯一值
229
229
  export function generateUniqueId() {
230
- return `${getUuid()}-${Date.now()}`;
230
+ return `${formatDate(new Date(), 'yyyy-MM-dd hh:mm:ss')}-${getUuid()}`;
231
231
  }
232
232
 
233
233
  export function getUuid () {
@@ -268,10 +268,9 @@ function getTableServices(lcpPageServiceMapVOList = [], { dynamicMapComp, dynami
268
268
  }
269
269
  return []
270
270
  }
271
-
272
271
  function parsePolyfillConfigs({ polyfillConfigs, instance, parentRootValue }, config) {
273
272
  const hireRelat = config.hireRelat
274
- const findKeys = Object.keys(polyfillConfigs).filter(key => hireRelat.endsWith(key))
273
+ const findKeys = Object.keys(polyfillConfigs || {}).filter(key => hireRelat.endsWith(key))
275
274
  if (!findKeys.length) {
276
275
  return
277
276
  }