impaktapps-ui-builder 0.0.101-alpha.336 → 0.0.101-alpha.337
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
|
@@ -103,35 +103,35 @@ export default (funcParams: funcParamsProps) => {
|
|
|
103
103
|
// funcParams.store.setFormdata((pre)=>({...pre,programId: programId}))
|
|
104
104
|
// }
|
|
105
105
|
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
106
|
+
const pathParts = funcParams.store.location.pathname.split("/");
|
|
107
|
+
const programId = JSON.parse(window.sessionStorage.getItem("ProgramID") || "{}")?.value || "programID";
|
|
108
|
+
if (config?.programIdRequired && programId) {
|
|
109
|
+
if (pathParts.length < 2) {
|
|
110
|
+
funcParams.store.navigate(
|
|
111
|
+
`${programId}/${funcParams.store.location.pathname}`
|
|
112
|
+
);
|
|
113
|
+
} else if(pathParts[1] !== programId+"") {
|
|
114
|
+
pathParts[1] = programId;
|
|
115
|
+
const newPath = pathParts.slice(0, 3).join("/");
|
|
116
|
+
funcParams.store.navigate(newPath);
|
|
117
|
+
}
|
|
118
|
+
}
|
|
119
119
|
const uiSchema = pageData?.uiSchema;
|
|
120
120
|
|
|
121
|
-
if (config?.programIdRequired) {
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
}
|
|
121
|
+
// if (config?.programIdRequired) {
|
|
122
|
+
// const programId =
|
|
123
|
+
// JSON.parse(window.sessionStorage.getItem("ProgramID") || "{}")?.value ||
|
|
124
|
+
// "programID";
|
|
125
|
+
// const queryParams = new URLSearchParams(location.search);
|
|
126
|
+
// console.log("queryParams ", queryParams);
|
|
127
|
+
// if (queryParams?.get("ProgramID") !== programId + "") {
|
|
128
|
+
// funcParams.store.setSearchParams({ ...queryParams, ProgramID: programId });
|
|
129
|
+
// // funcParams.store.navigate(0);
|
|
130
|
+
// }
|
|
131
|
+
// if (programId !== "programID") {
|
|
132
|
+
// funcParams.store.setFormdata((pre) => ({ ...pre, programId: programId }));
|
|
133
|
+
// }
|
|
134
|
+
// }
|
|
135
135
|
|
|
136
136
|
const event = new CustomEvent('pageNameChanged', {
|
|
137
137
|
detail: { pageName: config.label }
|