Showing
6 changed files
with
105 additions
and
25 deletions
| ... | @@ -13,11 +13,6 @@ | ... | @@ -13,11 +13,6 @@ |
| 13 | </van-col> | 13 | </van-col> |
| 14 | </van-row> | 14 | </van-row> |
| 15 | <router-view v-else></router-view> | 15 | <router-view v-else></router-view> |
| 16 | - <div | ||
| 17 | - style="text-align: center; color: #545454; font-size: 0.85rem; padding-bottom: 1rem" | ||
| 18 | - > | ||
| 19 | - 提交即授权该表单收集你的填写信息 | ||
| 20 | - </div> | ||
| 21 | </template> | 16 | </template> |
| 22 | 17 | ||
| 23 | <script setup> | 18 | <script setup> |
| ... | @@ -74,10 +69,6 @@ onMounted(async () => { | ... | @@ -74,10 +69,6 @@ onMounted(async () => { |
| 74 | // wx.error((err) => { | 69 | // wx.error((err) => { |
| 75 | // console.warn(err); | 70 | // console.warn(err); |
| 76 | // }); | 71 | // }); |
| 77 | - // TAG: 全局背景色 | ||
| 78 | - document | ||
| 79 | - .querySelector("body") | ||
| 80 | - .setAttribute("style", `background-color: ${styleColor.backgroundColor}`); | ||
| 81 | }); | 72 | }); |
| 82 | </script> | 73 | </script> |
| 83 | 74 | ... | ... |
src/assets/images/que-sucess@2x.png
0 → 100644
9.58 KB
| ... | @@ -17,15 +17,15 @@ | ... | @@ -17,15 +17,15 @@ |
| 17 | > | 17 | > |
| 18 | {{ item.component_props.note }} | 18 | {{ item.component_props.note }} |
| 19 | </div> | 19 | </div> |
| 20 | - <div style="font-size: 0.9rem"> | 20 | + <div> |
| 21 | <p | 21 | <p |
| 22 | v-for="file in fileList" | 22 | v-for="file in fileList" |
| 23 | :key="index" | 23 | :key="index" |
| 24 | style="padding-left: 1rem; margin-bottom: 0.5rem" | 24 | style="padding-left: 1rem; margin-bottom: 0.5rem" |
| 25 | > | 25 | > |
| 26 | - {{ file.filename }} <span | 26 | + <span style="font-size: 1rem">{{ file.filename }}</span |
| 27 | - style="color: #e32525" | 27 | + > |
| 28 | - @click="beforeDelete(file)" | 28 | + <span style="color: #e32525; font-size: 0.85rem" @click="beforeDelete(file)" |
| 29 | >移除</span | 29 | >移除</span |
| 30 | > | 30 | > |
| 31 | </p> | 31 | </p> | ... | ... |
| 1 | /* | 1 | /* |
| 2 | * @Date: 2022-07-18 10:22:22 | 2 | * @Date: 2022-07-18 10:22:22 |
| 3 | * @LastEditors: hookehuyr hookehuyr@gmail.com | 3 | * @LastEditors: hookehuyr hookehuyr@gmail.com |
| 4 | - * @LastEditTime: 2022-07-19 17:17:38 | 4 | + * @LastEditTime: 2022-12-05 16:58:59 |
| 5 | - * @FilePath: /front/src/route.js | 5 | + * @FilePath: /data-table/src/route.js |
| 6 | * @Description: 文件描述 | 6 | * @Description: 文件描述 |
| 7 | */ | 7 | */ |
| 8 | export default [{ | 8 | export default [{ |
| ... | @@ -11,4 +11,10 @@ export default [{ | ... | @@ -11,4 +11,10 @@ export default [{ |
| 11 | meta: { | 11 | meta: { |
| 12 | title: '首页', | 12 | title: '首页', |
| 13 | } | 13 | } |
| 14 | +}, { | ||
| 15 | + path: '/success', | ||
| 16 | + component: () => import('@/views/success.vue'), | ||
| 17 | + meta: { | ||
| 18 | + title: '提交成功', | ||
| 19 | + } | ||
| 14 | }]; | 20 | }]; | ... | ... |
| ... | @@ -47,18 +47,13 @@ | ... | @@ -47,18 +47,13 @@ |
| 47 | </van-form> | 47 | </van-form> |
| 48 | </van-config-provider> | 48 | </van-config-provider> |
| 49 | </div> | 49 | </div> |
| 50 | + <div | ||
| 51 | + style="text-align: center; color: #545454; font-size: 0.85rem; padding-bottom: 1rem" | ||
| 52 | + > | ||
| 53 | + 提交即授权该表单收集你的填写信息 | ||
| 54 | + </div> | ||
| 50 | </template> | 55 | </template> |
| 51 | 56 | ||
| 52 | -<script> | ||
| 53 | -export default { | ||
| 54 | - mounted() { | ||
| 55 | - setTimeout(() => { | ||
| 56 | - // console.warn(this.$refs); | ||
| 57 | - }, 100); | ||
| 58 | - }, | ||
| 59 | -}; | ||
| 60 | -</script> | ||
| 61 | - | ||
| 62 | <script setup> | 57 | <script setup> |
| 63 | import "@vant/touch-emulator"; | 58 | import "@vant/touch-emulator"; |
| 64 | import { createComponentType } from "@/hooks/useComponentType"; | 59 | import { createComponentType } from "@/hooks/useComponentType"; |
| ... | @@ -85,6 +80,7 @@ const themeVars = { | ... | @@ -85,6 +80,7 @@ const themeVars = { |
| 85 | }; | 80 | }; |
| 86 | 81 | ||
| 87 | const $route = useRoute(); | 82 | const $route = useRoute(); |
| 83 | +const $router = useRouter(); | ||
| 88 | const PHeader = ref({}); | 84 | const PHeader = ref({}); |
| 89 | const PHeader_cover = ref(""); | 85 | const PHeader_cover = ref(""); |
| 90 | const PHeader_title = ref(""); | 86 | const PHeader_title = ref(""); |
| ... | @@ -150,6 +146,10 @@ const setRefMap = (el, item) => { | ... | @@ -150,6 +146,10 @@ const setRefMap = (el, item) => { |
| 150 | }; | 146 | }; |
| 151 | 147 | ||
| 152 | onMounted(async () => { | 148 | onMounted(async () => { |
| 149 | + // TAG: 全局背景色 | ||
| 150 | + document | ||
| 151 | + .querySelector("body") | ||
| 152 | + .setAttribute("style", `background-color: ${styleColor.backgroundColor}`); | ||
| 153 | const { data } = await queryFormAPI({ form_code: $route.query.code }); | 153 | const { data } = await queryFormAPI({ form_code: $route.query.code }); |
| 154 | const form_data = data[0]; | 154 | const form_data = data[0]; |
| 155 | // 重构数据结构 | 155 | // 重构数据结构 |
| ... | @@ -287,6 +287,9 @@ const onSubmit = async (values) => { | ... | @@ -287,6 +287,9 @@ const onSubmit = async (values) => { |
| 287 | }); | 287 | }); |
| 288 | if (result.code) { | 288 | if (result.code) { |
| 289 | showSuccessToast("提交成功"); | 289 | showSuccessToast("提交成功"); |
| 290 | + $router.push({ | ||
| 291 | + path: "/success", | ||
| 292 | + }); | ||
| 290 | } | 293 | } |
| 291 | } else { | 294 | } else { |
| 292 | console.warn(validOther().key + "不通过验证"); | 295 | console.warn(validOther().key + "不通过验证"); | ... | ... |
src/views/success.vue
0 → 100644
| 1 | +<!-- | ||
| 2 | + * @Date: 2022-06-29 18:18:02 | ||
| 3 | + * @LastEditors: hookehuyr hookehuyr@gmail.com | ||
| 4 | + * @LastEditTime: 2022-06-29 18:18:09 | ||
| 5 | + * @FilePath: /tswj/src/views/test/404.vue | ||
| 6 | + * @Description: 文件描述 | ||
| 7 | +--> | ||
| 8 | +<template> | ||
| 9 | + <div class="success-page"> | ||
| 10 | + <div style="padding-top: 2rem; padding-bottom: 2rem; text-align: center"> | ||
| 11 | + <van-image | ||
| 12 | + round | ||
| 13 | + width="10rem" | ||
| 14 | + height="10rem" | ||
| 15 | + style="vertical-align: bottom" | ||
| 16 | + :src="icon_success" | ||
| 17 | + /> | ||
| 18 | + <p style="font-size: 1.05rem; margin: 0.5rem; font-weight: bold">提交成功!</p> | ||
| 19 | + <!-- <p style="font-size: 0.9rem; margin-bottom: 0.5rem">您的作品正在审核中</p> --> | ||
| 20 | + <!-- <p style="font-size: 0.9rem">请耐心等待~~</p> --> | ||
| 21 | + </div> | ||
| 22 | + <div style="padding: 0 15% 1rem 15%"> | ||
| 23 | + <div class="button-plain" :style="styleObj" @click="handle">返回</div> | ||
| 24 | + </div> | ||
| 25 | + </div> | ||
| 26 | +</template> | ||
| 27 | + | ||
| 28 | +<script setup> | ||
| 29 | +import { ref } from "vue"; | ||
| 30 | +import { useRoute, useRouter } from "vue-router"; | ||
| 31 | +import { styleColor } from "@/constant.js"; | ||
| 32 | +import icon_success from "@images/que-sucess@2x.png"; | ||
| 33 | + | ||
| 34 | +import { | ||
| 35 | + Cookies, | ||
| 36 | + $, | ||
| 37 | + _, | ||
| 38 | + axios, | ||
| 39 | + storeToRefs, | ||
| 40 | + mainStore, | ||
| 41 | + Toast, | ||
| 42 | + useTitle, | ||
| 43 | +} from "@/utils/generatePackage.js"; | ||
| 44 | +//import { } from '@/utils/generateModules.js' | ||
| 45 | +//import { } from '@/utils/generateIcons.js' | ||
| 46 | +//import { } from '@/composables' | ||
| 47 | +const $route = useRoute(); | ||
| 48 | +const $router = useRouter(); | ||
| 49 | +useTitle($route.meta.title); | ||
| 50 | + | ||
| 51 | +const styleObj = { | ||
| 52 | + background: styleColor.baseColor, | ||
| 53 | + border: styleColor.baseColor, | ||
| 54 | + color: "#FFFFFF", | ||
| 55 | +}; | ||
| 56 | + | ||
| 57 | +onMounted(() => {}); | ||
| 58 | + | ||
| 59 | +const handle = () => { | ||
| 60 | + $router.go(-1); | ||
| 61 | +}; | ||
| 62 | +</script> | ||
| 63 | + | ||
| 64 | +<style lang="less" scoped> | ||
| 65 | +.success-page { | ||
| 66 | + .button-plain { | ||
| 67 | + width: auto; | ||
| 68 | + height: auto; | ||
| 69 | + text-align: center; | ||
| 70 | + padding: 0.6rem; | ||
| 71 | + margin: 0.5rem; | ||
| 72 | + font-size: 1rem; | ||
| 73 | + // background: @base-font-color; | ||
| 74 | + border-radius: 24px; | ||
| 75 | + // border: 1px solid @base-color; | ||
| 76 | + // color: @base-color; | ||
| 77 | + font-weight: bold; | ||
| 78 | + } | ||
| 79 | +} | ||
| 80 | +</style> |
-
Please register or login to post a comment