App.vue 715 B

123456789101112131415161718192021222324252627282930313233343536
  1. <script>
  2. export default {
  3. methods: {},
  4. onShow() {
  5. uni.getStorage({
  6. key: "laocui_user_token",
  7. success: function (res) {
  8. // console.log("resresresresresresresresresres", res);
  9. // uni.switchTab({
  10. // url: "/pages/index/index",
  11. // });
  12. },
  13. fail(res) {
  14. console.log("resresresresresresresresresres", res);
  15. uni.redirectTo({
  16. url: "/pages/login/login",
  17. });
  18. },
  19. });
  20. },
  21. };
  22. </script>
  23. <style lang="scss">
  24. @import "./common/uni.css";
  25. @import "/wxcomponents/weapp/dist/common/index.wxss";
  26. @import "./common/style/index.scss";
  27. //@media screen and (min-width: 768px) {
  28. // body {
  29. // overflow-y: scroll;
  30. // }
  31. //}
  32. </style>