App.vue 441 B

1234567891011121314151617181920212223242526272829
  1. <template>
  2. <div id="app">
  3. <router-view />
  4. </div>
  5. </template>
  6. <script>
  7. export default {
  8. name: "App",
  9. data() {
  10. return {
  11. isDesktop: false,
  12. };
  13. },
  14. created() {
  15. this.$store.dispatch("getCommonBaseHomeList");
  16. if (!this.$store.state.isDesktop) {
  17. this.$request.getWeAppLink().then((res) => {
  18. res.msg && (window.location.href = res.msg);
  19. });
  20. }
  21. },
  22. };
  23. </script>
  24. <style>
  25. #app {
  26. }
  27. </style>