hookehuyr

fix

Showing 1 changed file with 14 additions and 20 deletions
...@@ -2,16 +2,11 @@ ...@@ -2,16 +2,11 @@
2 * @Author: hookehuyr hookehuyr@gmail.com 2 * @Author: hookehuyr hookehuyr@gmail.com
3 * @Date: 2022-05-26 23:52:36 3 * @Date: 2022-05-26 23:52:36
4 * @LastEditors: hookehuyr hookehuyr@gmail.com 4 * @LastEditors: hookehuyr hookehuyr@gmail.com
5 - * @LastEditTime: 2024-08-12 11:12:35 5 + * @LastEditTime: 2024-08-12 12:36:07
6 * @FilePath: /data-table/src/App.vue 6 * @FilePath: /data-table/src/App.vue
7 * @Description: 7 * @Description:
8 --> 8 -->
9 <template> 9 <template>
10 - <!-- <van-row v-if="is_pc">
11 - <van-col span="24">
12 - <router-view></router-view>
13 - </van-col>
14 - </van-row> -->
15 <router-view></router-view> 10 <router-view></router-view>
16 </template> 11 </template>
17 12
...@@ -19,7 +14,7 @@ ...@@ -19,7 +14,7 @@
19 import { mainStore, useTitle } from "@/utils/generatePackage"; 14 import { mainStore, useTitle } from "@/utils/generatePackage";
20 import { computed, watchEffect, onMounted } from "vue"; 15 import { computed, watchEffect, onMounted } from "vue";
21 import { useRoute, useRouter } from "vue-router"; 16 import { useRoute, useRouter } from "vue-router";
22 -import { Toast } from "vant"; 17 +// import { Toast } from "vant";
23 // 会根据配置判断是否显示调试控件 18 // 会根据配置判断是否显示调试控件
24 // eslint-disable-next-line no-unused-vars 19 // eslint-disable-next-line no-unused-vars
25 import vConsole from "@/utils/vconsole"; 20 import vConsole from "@/utils/vconsole";
...@@ -31,29 +26,28 @@ import { wxInfo, getUrlParams, stringifyQuery } from "@/utils/tools"; ...@@ -31,29 +26,28 @@ import { wxInfo, getUrlParams, stringifyQuery } from "@/utils/tools";
31 import { styleColor } from "@/constant.js"; 26 import { styleColor } from "@/constant.js";
32 import { getFormSettingAPI } from "@/api/form.js"; 27 import { getFormSettingAPI } from "@/api/form.js";
33 import { showDialog, showConfirmDialog } from 'vant'; 28 import { showDialog, showConfirmDialog } from 'vant';
34 -import fp3 from '@/utils/fp3'; 29 +// import fp3 from '@/utils/fp3';
35 import { Updater } from '@/utils/versionUpdater'; 30 import { Updater } from '@/utils/versionUpdater';
36 31
37 // 使用 include + pinia 状态管理动态缓存页面 32 // 使用 include + pinia 状态管理动态缓存页面
38 const store = mainStore(); 33 const store = mainStore();
39 const keepPages = computed(() => store.getKeepPages); 34 const keepPages = computed(() => store.getKeepPages);
40 35
41 -// // TAG: 全局设置页面标题 36 +// TAG: 全局设置页面标题
42 const $route = useRoute(); 37 const $route = useRoute();
43 // watchEffect(() => useTitle("表单标题")); 38 // watchEffect(() => useTitle("表单标题"));
44 // 监听路由变化 39 // 监听路由变化
45 // 切换路由页面返回顶部 40 // 切换路由页面返回顶部
46 const $router = useRouter(); 41 const $router = useRouter();
47 -watch( 42 +// watch(
48 - () => $router.currentRoute.value, 43 +// () => $router.currentRoute.value,
49 - (newValue, oldValue) => { 44 +// (newValue, oldValue) => {
50 - nextTick(() => { 45 +// nextTick(() => {
51 - // document.getElementById('app')?.scrollIntoView(); 46 +// // document.getElementById('app')?.scrollIntoView();
52 - }); 47 +// });
53 - // console.warn(wxInfo().isMobile); 48 +// },
54 - }, 49 +// { immediate: true }
55 - { immediate: true } 50 +// );
56 -);
57 51
58 // TAG: 全局配置Toast 52 // TAG: 全局配置Toast
59 // Toast.setDefaultOptions({ 53 // Toast.setDefaultOptions({
...@@ -98,7 +92,7 @@ onMounted(async () => { ...@@ -98,7 +92,7 @@ onMounted(async () => {
98 } 92 }
99 // 缓存表单设置 93 // 缓存表单设置
100 store.changeFormSetting(form_setting); 94 store.changeFormSetting(form_setting);
101 - // 跳转未授权页 95 + // TAG: 跳转未授权页
102 if (form_setting.auth_error) { // 权限报错信息存在 96 if (form_setting.auth_error) { // 权限报错信息存在
103 $router.replace({ 97 $router.replace({
104 path: '/no_auth', 98 path: '/no_auth',
......