App.vue 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970
  1. <script>
  2. export default {
  3. // 此处globalData为了演示其作用,不是uView框架的一部分
  4. globalData: {
  5. username: '白居易',
  6. base_url:'/api'
  7. },
  8. onLaunch() {
  9. // console.log(this.$store.state.vuex_user,'ppp')
  10. // let is_login=this.$store.state.vuex_user
  11. // if(!is_login){
  12. // console.log(this.$store.state.vuex_user,'ppp')
  13. // uni.reLaunch({
  14. // url:'/pages/login/index'
  15. // })
  16. // }else{
  17. // }
  18. // 1.1.0版本之前关于http拦截器代码,已平滑移动到/common/http.interceptor.js中
  19. // 注意,需要在/main.js中实例化Vue之后引入如下(详见文档说明):
  20. // import httpInterceptor from '@/common/http.interceptor.js'
  21. // Vue.use(httpInterceptor, app)
  22. // process.env.VUE_APP_PLATFORM 为通过js判断平台名称的方法,结果分别如下:
  23. /**
  24. * h5,app-plus(nvue下也为app-plus),mp-weixin,mp-alipay......
  25. */
  26. },
  27. }
  28. </script>
  29. <style lang="scss">
  30. @import "uview-ui/index.scss";
  31. @import "common/demo.scss";
  32. // page{
  33. // padding: 15px 0;
  34. // }
  35. .bg{
  36. background: url(./static/images/bg.png) no-repeat;
  37. background-color: #F9F9FB;
  38. background-position: center;
  39. background-position-y: 100px;
  40. background-position-x: 50px;
  41. height: 100vh;
  42. width: 100vh;
  43. overflow: hidden;
  44. position: fixed;
  45. top: 0;
  46. left: 0;
  47. z-index: 0;
  48. }
  49. .position{
  50. position: relative;
  51. z-index: 1;
  52. }
  53. .empty{
  54. margin-top: 20%;
  55. text-align: center;
  56. image{
  57. display: inline-block;
  58. width: 30%;
  59. }
  60. .empty-text{
  61. margin-top: 20px;
  62. font-size: 14px;
  63. color: rgba(113, 113, 113, 0.43);
  64. }
  65. }
  66. </style>