resolver-egretimp-plus 0.0.29 → 0.0.30

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.29",
3
+ "version": "0.0.30",
4
4
  "description": "交付体验渲染",
5
5
  "main": "./dist/web/index.js",
6
6
  "module": "./dist/web/index.js",
@@ -26,4 +26,14 @@ export async function executeLoadServices(services = [], { axiosInstance, messag
26
26
  }
27
27
  respCb && respCb(ret?.data?.result)
28
28
  }
29
+ }
30
+
31
+ export function normalPageConfigs(pageConfig) {
32
+ const rootOptionComp = pageConfig?.pmPageMetaList?.find(item => item.metaCode === 'PC-root-panel')
33
+ if (rootOptionComp) {
34
+ pageConfig.pmPageMetaList = rootOptionComp.pmPageMetaList
35
+ delete rootOptionComp.pmPageMetaList
36
+ pageConfig.rootOptionComp = rootOptionComp
37
+ }
38
+ return pageConfig
29
39
  }
@@ -2,6 +2,7 @@ import { parsePageConfig } from "../utils"
2
2
  import { ref } from 'vue'
3
3
  import { buildInRequest } from "../utils/request"
4
4
  import { GET_SYS_PARAM_CACHE, QUERY_PAGE_CONFIG_DATA } from "../api/builtIn"
5
+ import { normalPageConfigs } from "../components/helper/resolver"
5
6
 
6
7
  export function usePageConfig() {
7
8
  const pageConfigRef = ref(null)
@@ -31,7 +32,7 @@ export function useBuildInData(messageTipInstance, loadingInstance) {
31
32
  }
32
33
  buildInRequest(QUERY_PAGE_CONFIG_DATA, reqData).then(ret => {
33
34
  if (ret.data.success) {
34
- pageConfig.value = ret.data.result
35
+ pageConfig.value = normalPageConfigs(ret.data.result)
35
36
  getSelects(ret.data.result?.pmBusinessIdentityVO?.tenantId)
36
37
  return
37
38
  }
package/src/index.jsx CHANGED
@@ -75,11 +75,11 @@ export default {
75
75
  default: () => ({composeComponents: {}})
76
76
  },
77
77
  loadingInstance: {
78
- type: Object,
78
+ type: [Object, Function],
79
79
  default: () => null
80
80
  },
81
81
  messageInstance: {
82
- type: Object,
82
+ type: [Object, Function],
83
83
  default: () => null
84
84
  },
85
85
  loadEvnetsReq: {
@@ -14,11 +14,11 @@ const props = defineProps({
14
14
  default: () => ({composeComponents: {}})
15
15
  },
16
16
  loadingInstance: {
17
- type: Object,
17
+ type: [Object, Function],
18
18
  default: () => null
19
19
  },
20
20
  messageInstance: {
21
- type: Object,
21
+ type: [Object, Function],
22
22
  default: () => null
23
23
  },
24
24
  })