From c9d31171b240e528818c831402f9bcb5d2dc5876 Mon Sep 17 00:00:00 2001 From: aixianling Date: Thu, 2 Dec 2021 17:41:00 +0800 Subject: [PATCH 1/3] BUG 25191 --- src/apps/AppAskForm/components/FiledConfig.vue | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/apps/AppAskForm/components/FiledConfig.vue b/src/apps/AppAskForm/components/FiledConfig.vue index d5098567..480184ce 100644 --- a/src/apps/AppAskForm/components/FiledConfig.vue +++ b/src/apps/AppAskForm/components/FiledConfig.vue @@ -2,7 +2,7 @@
- +
@@ -174,7 +174,7 @@ export default { let index = 0 if (this.config.answer) { - this.config.options.forEach((v, i) => { + this.config.options?.forEach((v, i) => { if (v.label === this.config.answer) { index = i } From 451d3b1f5c455ed516b845b6560934180cbc5cf5 Mon Sep 17 00:00:00 2001 From: aixianling Date: Thu, 2 Dec 2021 17:44:51 +0800 Subject: [PATCH 2/3] BUG 25187 --- src/apps/AppAskForm/formDetail.vue | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/apps/AppAskForm/formDetail.vue b/src/apps/AppAskForm/formDetail.vue index 4179d34b..acf45327 100644 --- a/src/apps/AppAskForm/formDetail.vue +++ b/src/apps/AppAskForm/formDetail.vue @@ -174,6 +174,8 @@ export default { tips: "提交成功!感谢参与", } } + }).catch(err => { + this.$u.toast(err || "提交失败") }) } }, From 82dbc510df56b517e755a0d336eaea97e3648653 Mon Sep 17 00:00:00 2001 From: aixianling Date: Thu, 2 Dec 2021 17:57:45 +0800 Subject: [PATCH 3/3] BUG 25155 --- src/apps/AppAskForm/AppForm.vue | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/src/apps/AppAskForm/AppForm.vue b/src/apps/AppAskForm/AppForm.vue index d7058bb9..ffc6eee5 100644 --- a/src/apps/AppAskForm/AppForm.vue +++ b/src/apps/AppAskForm/AppForm.vue @@ -19,7 +19,8 @@ export default { components: {AiResult, FormDetail}, data() { return { - access: false + access: false, + err: "" } }, computed: { @@ -28,7 +29,7 @@ export default { return !!this.$route.query?.id && this.access }, errMsg() { - return this.access ? "表单不存在" : "无法获取用户信息" + return this.err || (this.access ? "表单不存在" : "无法获取用户信息") }, isPreview() { return !!this.$route.query?.preview @@ -37,11 +38,19 @@ export default { methods: { ...mapActions(['getCode', 'getToken']), checkAccess() { - let {corpId, code, suiteId} = this.$route.query + let {corpId, code, suiteId, id} = this.$route.query if (this.isPreview) { this.access = true } else if (!!this.token) { - this.access = true + this.$http.post("/app/appquestionnairetemplate/commitCheck", null, { + params: {id} + }).then(res => { + if (res?.code == 0) { + this.access = true + } + }).catch(err => { + this.err = err + }) } else if (code) { this.getToken({code, corpId, suiteId, isAppForm: true}).then(() => { let {query, path, hash} = this.$route