index.vue 830 B

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. <template>
  2. <view class="page">
  3. <uni-nav-bar :fixed="true" background-color="#FFE05C" :border="false" :statusBar="true" title="首页" />
  4. <manager :height="height" v-if="userInfo.isManager === 1"></manager>
  5. <attach :height="height" v-else></attach>
  6. </view>
  7. </template>
  8. <script>
  9. import manager from "./manager/manager";
  10. import attach from "./attach/attach"
  11. export default {
  12. components:{
  13. manager,attach
  14. },
  15. data() {
  16. return {
  17. height:'',
  18. ruleList:[],
  19. roleList:[],
  20. roleBindRuleParam:{},
  21. userInfo:{}
  22. }
  23. },
  24. onLoad() {
  25. let sysInfo = uni.getSystemInfoSync()
  26. this.height = sysInfo.windowHeight - 45 + 'px'
  27. },
  28. onShow(){
  29. this.userInfo = uni.getStorageSync('spreadUserInfo')
  30. },
  31. methods: {
  32. }
  33. }
  34. </script>
  35. <style scoped lang="scss">
  36. @import './index.rpx.css';
  37. </style>