Co-authored-by: jiangchunfu <jiangchunfu@kaike.la>
This commit is contained in:
parent
23f4dd5756
commit
28591f00a3
@ -2,7 +2,7 @@
|
||||
<router-view></router-view>
|
||||
</template>
|
||||
<script setup lang="ts">
|
||||
import { onMounted } from 'vue'
|
||||
import { onMounted, watch } from 'vue'
|
||||
import { useRoute } from 'vue-router'
|
||||
|
||||
import { getPublishedSurveyInfo, getPreviewSchema } from '../api/survey'
|
||||
@ -56,6 +56,13 @@ onMounted(() => {
|
||||
getDetail(surveyId as string)
|
||||
})
|
||||
|
||||
watch(
|
||||
() => route.query.t,
|
||||
() => {
|
||||
location.reload()
|
||||
}
|
||||
)
|
||||
|
||||
const getDetail = async (surveyPath: string) => {
|
||||
const alert = useCommandComponent(AlertDialog)
|
||||
|
||||
|
@ -16,6 +16,7 @@
|
||||
></SubmitButton>
|
||||
</div>
|
||||
<LogoIcon :logo-conf="logoConf" :readonly="true" />
|
||||
<VerifyWhiteDialog />
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
@ -112,7 +113,7 @@ const submitSurver = async () => {
|
||||
console.log(params)
|
||||
const res: any = await submitForm(params)
|
||||
if (res.code === 200) {
|
||||
router.push({ name: 'successPage' })
|
||||
router.replace({ name: 'successPage' })
|
||||
} else {
|
||||
alert({
|
||||
title: res.errmsg || '提交失败'
|
||||
|
@ -4,6 +4,18 @@
|
||||
<div class="result-content">
|
||||
<img src="/imgs/icons/success.webp" />
|
||||
<div class="msg" v-html="successMsg"></div>
|
||||
<router-link
|
||||
:to="{
|
||||
name: 'renderPage',
|
||||
query: {
|
||||
t: new Date().getTime()
|
||||
}
|
||||
}"
|
||||
replace
|
||||
class="reset-link"
|
||||
>
|
||||
重新填写
|
||||
</router-link>
|
||||
</div>
|
||||
<LogoIcon :logo-conf="logoConf" :readonly="true" />
|
||||
</div>
|
||||
@ -65,5 +77,13 @@ const successMsg = computed(() => {
|
||||
font-weight: 500;
|
||||
margin-top: 0.15rem;
|
||||
}
|
||||
|
||||
.reset-link {
|
||||
margin-top: 0.24rem;
|
||||
font-size: 0.27rem;
|
||||
color: #5094f0;
|
||||
text-decoration: underline;
|
||||
display: block;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
Loading…
Reference in New Issue
Block a user