App.vue 856 B

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. <script>
  2. import * as api from 'common/api/index.js'
  3. const getConfigData = () => {
  4. api.getConfig()
  5. .then((res) => {
  6. if (res.code == 200) {
  7. uni.setStorageSync("configs", res.data)
  8. }
  9. })
  10. .catch((err) => {
  11. });
  12. }
  13. export default {
  14. onLaunch: async (options) => {
  15. uni.hideTabBar()
  16. getConfigData()
  17. },
  18. onShow: function () {
  19. },
  20. onHide: function () {
  21. },
  22. };
  23. </script>
  24. <style lang="scss">
  25. @import "@/components/uview-ui/index.scss";
  26. @import "./common/styles/common.scss";
  27. /*每个页面公共css */
  28. page {
  29. font-family: "PingFang SC";
  30. -webkit-font-smoothing: antialiased;
  31. -moz-osx-font-smoothing: grayscale;
  32. height: 100%;
  33. font-size: 28rpx;
  34. color: $fontMain;
  35. background: #F5F6F8;
  36. view {
  37. display: block;
  38. flex-direction: row;
  39. // box-sizing: border-box;
  40. }
  41. }
  42. </style>