Showing
8 changed files
with
19 additions
and
83 deletions
| ... | @@ -2,7 +2,7 @@ | ... | @@ -2,7 +2,7 @@ |
| 2 | * @Author: hookehuyr hookehuyr@gmail.com | 2 | * @Author: hookehuyr hookehuyr@gmail.com |
| 3 | * @Date: 2022-05-31 12:06:19 | 3 | * @Date: 2022-05-31 12:06:19 |
| 4 | * @LastEditors: hookehuyr hookehuyr@gmail.com | 4 | * @LastEditors: hookehuyr hookehuyr@gmail.com |
| 5 | - * @LastEditTime: 2022-06-09 02:02:04 | 5 | + * @LastEditTime: 2022-06-29 22:00:37 |
| 6 | * @FilePath: /tswj/src/main.js | 6 | * @FilePath: /tswj/src/main.js |
| 7 | * @Description: | 7 | * @Description: |
| 8 | */ | 8 | */ |
| ... | @@ -20,8 +20,6 @@ const app = createApp(App); | ... | @@ -20,8 +20,6 @@ const app = createApp(App); |
| 20 | 20 | ||
| 21 | app.config.globalProperties.$http = axios; // 关键语句 | 21 | app.config.globalProperties.$http = axios; // 关键语句 |
| 22 | 22 | ||
| 23 | -app.use(pinia).use(router).use(Button).use(VanImage).use(Col).use(Row).use(Icon).use(Form).use(Field).use(CellGroup).use(Toast).use(Uploader).use(Empty).use(Tab).use(Tabs).use(Overlay).use(NumberKeyboard).use(Lazyload).use(List).use(PullRefresh).use(Popup).use(Picker).use(Sticky).use(Stepper).use(Tag).use(Swipe).use(SwipeItem).use(Dialog).use(ActionSheet).use(Loading).use(Checkbox).use(Search); | 23 | +app.use(pinia).use(router).use(Button).use(VanImage).use(Col).use(Row).use(Icon).use(Form).use(Field).use(CellGroup).use(Toast).use(Uploader).use(Empty).use(Tab).use(Tabs).use(Overlay).use(NumberKeyboard).use(Lazyload).use(List).use(PullRefresh).use(Popup).use(Picker).use(Sticky).use(Stepper).use(Tag).use(Swipe).use(SwipeItem).use(Dialog).use(ActionSheet).use(Loading).use(Checkbox).use(Search).use(ConfigProvider); |
| 24 | - | ||
| 25 | -app.use(ConfigProvider); | ||
| 26 | 24 | ||
| 27 | app.mount('#app'); | 25 | app.mount('#app'); | ... | ... |
| 1 | /* | 1 | /* |
| 2 | * @Date: 2022-05-26 13:57:28 | 2 | * @Date: 2022-05-26 13:57:28 |
| 3 | * @LastEditors: hookehuyr hookehuyr@gmail.com | 3 | * @LastEditors: hookehuyr hookehuyr@gmail.com |
| 4 | - * @LastEditTime: 2022-06-29 20:06:11 | 4 | + * @LastEditTime: 2022-06-29 21:36:59 |
| 5 | * @FilePath: /tswj/src/router.js | 5 | * @FilePath: /tswj/src/router.js |
| 6 | * @Description: 文件描述 | 6 | * @Description: 文件描述 |
| 7 | */ | 7 | */ |
| ... | @@ -35,7 +35,7 @@ const router = createRouter({ | ... | @@ -35,7 +35,7 @@ const router = createRouter({ |
| 35 | * generateRoute 负责把后台返回数据拼接成项目需要的路由结构,动态添加到路由表里面 | 35 | * generateRoute 负责把后台返回数据拼接成项目需要的路由结构,动态添加到路由表里面 |
| 36 | */ | 36 | */ |
| 37 | router.beforeEach((to, from, next) => { | 37 | router.beforeEach((to, from, next) => { |
| 38 | - // 使用404为中转页面,避免动态路由没有渲染出来,控制台报错问题 | 38 | + // 使用404为中转页面,避免动态路由没有渲染出来,控制台报警告问题 |
| 39 | if (to.path == '/404' && to.redirectedFrom != undefined) { | 39 | if (to.path == '/404' && to.redirectedFrom != undefined) { |
| 40 | // 模拟异步操作 | 40 | // 模拟异步操作 |
| 41 | setTimeout(() => { | 41 | setTimeout(() => { | ... | ... |
| ... | @@ -3,37 +3,7 @@ | ... | @@ -3,37 +3,7 @@ |
| 3 | </template> | 3 | </template> |
| 4 | 4 | ||
| 5 | <script setup> | 5 | <script setup> |
| 6 | -import { ref } from 'vue' | ||
| 7 | -import { useRoute, useRouter } from 'vue-router' | ||
| 8 | - | ||
| 9 | -import { Cookies, $, _, axios, storeToRefs, mainStore, Toast } from '@/utils/generatePackage.js' | ||
| 10 | -//import { } from '@/utils/generateModules.js' | ||
| 11 | -//import { } from '@/utils/generateIcons.js' | ||
| 12 | -//import { } from '@/composables' | ||
| 13 | -const $route = useRoute(); | ||
| 14 | -const $router = useRouter(); | ||
| 15 | - | ||
| 16 | -</script> | ||
| 17 | - | ||
| 18 | -<script> | ||
| 19 | -import mixin from 'common/mixin'; | ||
| 20 | - | ||
| 21 | -export default { | ||
| 22 | - mixins: [mixin.init], | ||
| 23 | - data () { | ||
| 24 | - return { | ||
| 25 | - | ||
| 26 | - } | ||
| 27 | - }, | ||
| 28 | - mounted () { | ||
| 29 | - | ||
| 30 | - }, | ||
| 31 | - methods: { | ||
| 32 | - | ||
| 33 | - } | ||
| 34 | -} | ||
| 35 | </script> | 6 | </script> |
| 36 | 7 | ||
| 37 | <style lang="less" scoped> | 8 | <style lang="less" scoped> |
| 38 | - | ||
| 39 | </style> | 9 | </style> | ... | ... |
| 1 | -<!-- | ||
| 2 | - * @Author: hookehuyr hookehuyr@gmail.com | ||
| 3 | - * @Date: 2022-05-14 22:27:32 | ||
| 4 | - * @LastEditors: hookehuyr hookehuyr@gmail.com | ||
| 5 | - * @LastEditTime: 2022-06-09 00:59:41 | ||
| 6 | - * @FilePath: /tswj/src/views/auth.vue | ||
| 7 | - * @Description: | ||
| 8 | ---> | ||
| 9 | <template> | 1 | <template> |
| 2 | + <div /> | ||
| 10 | </template> | 3 | </template> |
| 11 | 4 | ||
| 12 | <script setup> | 5 | <script setup> | ... | ... |
| 1 | <!-- | 1 | <!-- |
| 2 | * @Date: 2022-06-29 15:57:45 | 2 | * @Date: 2022-06-29 15:57:45 |
| 3 | * @LastEditors: hookehuyr hookehuyr@gmail.com | 3 | * @LastEditors: hookehuyr hookehuyr@gmail.com |
| 4 | - * @LastEditTime: 2022-06-29 15:57:52 | 4 | + * @LastEditTime: 2022-06-29 22:04:25 |
| 5 | * @FilePath: /tswj/src/views/children-test.vue | 5 | * @FilePath: /tswj/src/views/children-test.vue |
| 6 | * @Description: 文件描述 | 6 | * @Description: 文件描述 |
| 7 | --> | 7 | --> |
| ... | @@ -10,19 +10,7 @@ | ... | @@ -10,19 +10,7 @@ |
| 10 | </template> | 10 | </template> |
| 11 | 11 | ||
| 12 | <script setup> | 12 | <script setup> |
| 13 | -import { ref } from 'vue' | ||
| 14 | -import { useRoute, useRouter } from 'vue-router' | ||
| 15 | - | ||
| 16 | -import { Cookies, $, _, axios, storeToRefs, mainStore, Toast, useTitle } from '@/utils/generatePackage.js' | ||
| 17 | -//import { } from '@/utils/generateModules.js' | ||
| 18 | -//import { } from '@/utils/generateIcons.js' | ||
| 19 | -//import { } from '@/composables' | ||
| 20 | -const $route = useRoute(); | ||
| 21 | -const $router = useRouter(); | ||
| 22 | -useTitle($route.meta.title); | ||
| 23 | - | ||
| 24 | </script> | 13 | </script> |
| 25 | 14 | ||
| 26 | <style lang="less" scoped> | 15 | <style lang="less" scoped> |
| 27 | - | ||
| 28 | </style> | 16 | </style> | ... | ... |
| ... | @@ -2,16 +2,16 @@ | ... | @@ -2,16 +2,16 @@ |
| 2 | <div> | 2 | <div> |
| 3 | <!-- 生成图片后隐藏原始结构 --> | 3 | <!-- 生成图片后隐藏原始结构 --> |
| 4 | <div v-if="flag" ref="canvasRef" style="width: 200px; height: 200px;"> | 4 | <div v-if="flag" ref="canvasRef" style="width: 200px; height: 200px;"> |
| 5 | - <img :src="logo_image" alt="" /> | 5 | + <img :src="logo_image" alt=""> |
| 6 | </div> | 6 | </div> |
| 7 | <div v-if="imgUrl"> | 7 | <div v-if="imgUrl"> |
| 8 | - <img :src="imgUrl" alt="" crossOrigin="anonymous" style="width: 300px; height: 300px;" /> | 8 | + <img :src="imgUrl" alt="" crossOrigin="anonymous" style="width: 300px; height: 300px;"> |
| 9 | </div> | 9 | </div> |
| 10 | <div> | 10 | <div> |
| 11 | <div @click="createImage">合成图片</div> | 11 | <div @click="createImage">合成图片</div> |
| 12 | <div @click="btn">child</div> | 12 | <div @click="btn">child</div> |
| 13 | </div> | 13 | </div> |
| 14 | - <router-view></router-view> | 14 | + <router-view /> |
| 15 | </div> | 15 | </div> |
| 16 | </template> | 16 | </template> |
| 17 | 17 | ||
| ... | @@ -65,8 +65,8 @@ export default { | ... | @@ -65,8 +65,8 @@ export default { |
| 65 | alert("图片跨域,保存失败"); | 65 | alert("图片跨域,保存失败"); |
| 66 | } | 66 | } |
| 67 | }) | 67 | }) |
| 68 | - .catch(err => { | 68 | + .catch(error => { |
| 69 | - console.log("绘制失败"); | 69 | + console.error("绘制失败"); |
| 70 | }); | 70 | }); |
| 71 | }); | 71 | }); |
| 72 | }, | 72 | }, | ... | ... |
| 1 | <template> | 1 | <template> |
| 2 | - <div></div> | 2 | + <div /> |
| 3 | </template> | 3 | </template> |
| 4 | 4 | ||
| 5 | <script setup> | 5 | <script setup> |
| 6 | - | ||
| 7 | -</script> | ||
| 8 | - | ||
| 9 | -<script> | ||
| 10 | -import mixin from 'common/mixin' | ||
| 11 | - | ||
| 12 | -export default { | ||
| 13 | - mixins: [mixin.init], | ||
| 14 | - data () { | ||
| 15 | - return { | ||
| 16 | - } | ||
| 17 | - }, | ||
| 18 | - mounted () { | ||
| 19 | - }, | ||
| 20 | - methods: { | ||
| 21 | - | ||
| 22 | - } | ||
| 23 | -} | ||
| 24 | </script> | 6 | </script> |
| 25 | 7 | ||
| 26 | <style lang="less" scoped> | 8 | <style lang="less" scoped> |
| 27 | - | ||
| 28 | </style> | 9 | </style> | ... | ... |
-
Please register or login to post a comment