Browse Source

Merge pull request #9720 from nocodb/nc-fix/form-view-prefill-issue

fix(nc-gui): prefill form decode query param issue
pull/9726/head
Ramesh Mane 1 month ago committed by GitHub
parent
commit
62ad252db4
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
  1. 6
      packages/nc-gui/components/dlg/share-and-collaborate/SharePage.vue
  2. 2
      packages/nc-gui/composables/useSharedFormViewStore.ts

6
packages/nc-gui/components/dlg/share-and-collaborate/SharePage.vue

@ -211,11 +211,9 @@ function sharedViewUrl() {
dashboardUrl1 = `${baseUrl}${appInfo.value?.dashboardPath}` dashboardUrl1 = `${baseUrl}${appInfo.value?.dashboardPath}`
} }
return encodeURI( return `${encodeURI(`${dashboardUrl1}#/nc/${viewType}/${activeView.value.uuid}${surveyMode.value ? '/survey' : ''}`)}${
`${dashboardUrl1}#/nc/${viewType}/${activeView.value.uuid}${surveyMode.value ? '/survey' : ''}${
viewStore.preFillFormSearchParams && formPreFill.value.preFillEnabled ? `?${viewStore.preFillFormSearchParams}` : '' viewStore.preFillFormSearchParams && formPreFill.value.preFillEnabled ? `?${viewStore.preFillFormSearchParams}` : ''
}`, }`
)
} }
const toggleViewShare = async () => { const toggleViewShare = async () => {

2
packages/nc-gui/composables/useSharedFormViewStore.ts

@ -443,7 +443,7 @@ const [useProvideSharedFormStore, useSharedFormStore] = useInjectionState((share
if (Object.keys(route.query || {}).length) { if (Object.keys(route.query || {}).length) {
columns.value = await Promise.all( columns.value = await Promise.all(
(columns.value || []).map(async (c) => { (columns.value || []).map(async (c) => {
const queryParam = route.query[c.title as string] || route.query[encodeURIComponent(c.title as string)] const queryParam = route.query[c.title as string]
if ( if (
!c.title || !c.title ||

Loading…
Cancel
Save