super-page-runtime 2.0.74 → 2.0.76

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.
@@ -2,7 +2,7 @@ import http from "agilebuilder-ui/src/utils/request";
2
2
  import { useRoute } from "vue-router";
3
3
  import { getAdditionalParamMap } from "./events/standard-event.js";
4
4
  import { PageDimensions } from "./interfaces/page-design-types.js";
5
- import { formatVariableValue, getFormPropName, setVariableValue } from "./page-helper-util.js";
5
+ import { setVariableValue, formatVariableValue, getFormPropName } from "./page-helper-util.js";
6
6
  import { getSessionCache } from "agilebuilder-ui/src/utils/auth";
7
7
  function queryPageDesignByCode(pageCode) {
8
8
  return http.get(
@@ -90,6 +90,9 @@ function getPageDimensions() {
90
90
  function getRequestObject(pageRequest) {
91
91
  const requestObj = {};
92
92
  if (pageRequest) {
93
+ const paramStoreId = pageRequest.paramStoreId;
94
+ packageAdditionalMap(paramStoreId, requestObj);
95
+ delete pageRequest.paramStoreId;
93
96
  Object.assign(requestObj, pageRequest);
94
97
  }
95
98
  let url = decodeURI(window.location.href);
@@ -109,20 +112,23 @@ function getRequestObject(pageRequest) {
109
112
  if (route.query) {
110
113
  Object.assign(requestObj, route.query);
111
114
  const paramStoreId = route.query.paramStoreId;
112
- if (paramStoreId) {
113
- const additionalParamMapJson = getSessionCache(paramStoreId);
114
- if (additionalParamMapJson) {
115
- const additionalParamMap = JSON.parse(additionalParamMapJson);
116
- Object.assign(requestObj, additionalParamMap);
117
- console.log("已获取到附加参数", additionalParamMap);
118
- }
119
- }
115
+ packageAdditionalMap(paramStoreId, requestObj);
120
116
  }
121
117
  }
122
118
  if (requestObj["_t_"])
123
119
  ;
124
120
  return requestObj;
125
121
  }
122
+ function packageAdditionalMap(paramStoreId, requestObj) {
123
+ if (paramStoreId) {
124
+ const additionalParamMapJson = getSessionCache(paramStoreId);
125
+ if (additionalParamMapJson) {
126
+ const additionalParamMap = JSON.parse(additionalParamMapJson);
127
+ Object.assign(requestObj, additionalParamMap);
128
+ console.log("已获取到附加参数", additionalParamMap);
129
+ }
130
+ }
131
+ }
126
132
  function getModelFields(pageContext, formItemConfigure, prop) {
127
133
  if (!formItemConfigure) {
128
134
  return ["temp"];
@@ -175,10 +181,8 @@ function getFormModelFields(pageContext, formItemConfigure, prop) {
175
181
  }
176
182
  function getDefaultValue(pageContext, defaultValueSet, componentType, multiple) {
177
183
  let defaultValue;
178
- console.log("pageRuntime11---getDefaultValue---defaultValueSet---", defaultValueSet, "pageContext=", pageContext);
179
184
  if (defaultValueSet) {
180
185
  defaultValue = formatVariableValue(pageContext, defaultValueSet);
181
- console.log("pageRuntime22---getDefaultValue---defaultValue---", defaultValue);
182
186
  if (defaultValue != null && defaultValue != void 0 && componentType) {
183
187
  let isMultiple = false;
184
188
  if (componentType == "checkbox") {
@@ -413,6 +413,10 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
413
413
  }
414
414
  const jumpMode = openPageParams.jumpMode;
415
415
  const popPageSetting = openPageParams;
416
+ if (!parentEventParams.value) {
417
+ parentEventParams.value = {};
418
+ }
419
+ parentEventParams.value.paramStoreId = openPageParams.paramStoreId;
416
420
  popPageSetting.parentPageCode = parentPageContext.value.code;
417
421
  popPageSetting.parentPageVersion = parentPageContext.value.version;
418
422
  popPageSetting.isNewPage = true;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "super-page-runtime",
3
- "version": "2.0.74",
3
+ "version": "2.0.76",
4
4
  "description": "AgileBuilder super page runtime",
5
5
  "license": "ISC",
6
6
  "main": "dist/es/index.js",
@@ -48,7 +48,7 @@
48
48
  "@vitejs/plugin-vue-jsx": "^3.1.0",
49
49
  "@vue/eslint-config-prettier": "^8.0.0",
50
50
  "@vue/test-utils": "^2.4.4",
51
- "agilebuilder-ui": "1.0.53",
51
+ "agilebuilder-ui": "1.0.55",
52
52
  "axios": "^1.6.8",
53
53
  "cypress": "^13.6.6",
54
54
  "element-plus": "^2.6.1",