index.vue 837 B

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. <template>
  2. <view class="index-box">
  3. <index-nav @setTabNum="setTabNum"></index-nav>
  4. <view class="list-box">
  5. <view class="box-one" v-if="tabNum===0">
  6. <attachment-list></attachment-list>
  7. </view>
  8. <view class="box-two" v-else-if="tabNum===1">
  9. <attachment-list></attachment-list>
  10. </view>
  11. <view class="box-three" v-else>
  12. <attachment-list></attachment-list>
  13. </view>
  14. </view>
  15. </view>
  16. </template>
  17. <script>
  18. import IndexNav from "@/pages/index/model/index-nav";
  19. import AttachmentList from "@/pages/index/model/attachment-list";
  20. export default {
  21. components: {AttachmentList, IndexNav},
  22. data() {
  23. return {
  24. tabNum:0
  25. }
  26. },
  27. methods: {
  28. setTabNum(tabNum){
  29. this.tabNum=tabNum
  30. }
  31. }
  32. }
  33. </script>
  34. <style scoped lang="scss">
  35. .index-box{
  36. }
  37. </style>