自主项目,食堂系统,前端uniapp
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

142 lines
3.4 KiB

  1. <template>
  2. <view>
  3. <view class="tabs">
  4. <u-tabs :list="tab_list" :is-scroll="false" :current="current" bg-color="#f6f6f6" active-color="#1833F2" @change="tabsChange"></u-tabs>
  5. </view>
  6. <swiper :style="{height: 'calc('+ windowHeight +'px - 110rpx)', width: '750rpx'}"
  7. :current="current" @change="swiperChange">
  8. <swiper-item v-for="(tabItem, tabIndex) in tab_list" :key="tabIndex">
  9. <scroll-view class="lf-w-100 lf-h-100 lf-p-l-32 lf-p-r-32 lf-border-box" :scroll-y="true">
  10. <view class="card" v-for="(item, index) in 10" :key="index" @click="$url('/pages/supply/gonghuo/detail')">
  11. <view class="lf-row-between item">
  12. <view class="lf-color-gray">采购方</view>
  13. <view class="lf-color-black">广西美味生活食堂有限公司</view>
  14. </view>
  15. <view class="lf-row-between item">
  16. <view class="lf-color-gray">发单时间</view>
  17. <view class="lf-color-black">2021-07-23 17:24:23</view>
  18. </view>
  19. <view class="lf-row-between item">
  20. <view class="lf-color-gray">送达时间</view>
  21. <view class="lf-color-black">2021-07-23 17:24:23</view>
  22. </view>
  23. <view class="lf-row-between item">
  24. <view class="lf-color-gray">商品种类</view>
  25. <view class="lf-color-black">8</view>
  26. </view>
  27. <view class="lf-row-between item">
  28. <view class="lf-color-gray">订单状态</view>
  29. <view class="quoted-price">等待接单</view>
  30. </view>
  31. </view>
  32. <view class="loading-more">
  33. <text :class="{'loading-more-text': tabItem.loading_class}">{{ tabItem.loading_text }}</text>
  34. <!-- <lf-nocontent></lf-nocontent> -->
  35. </view>
  36. </scroll-view>
  37. </swiper-item>
  38. </swiper>
  39. </view>
  40. </template>
  41. <script>
  42. export default {
  43. data(){
  44. return {
  45. current: 0,
  46. tab_list: [{
  47. name: '全部',
  48. loading_class: true,
  49. loading_text: '正在加载中...',
  50. page: 1,
  51. isPage: true,
  52. list: []
  53. },{
  54. name: '待接单',
  55. loading_class: true,
  56. loading_text: '正在加载中...',
  57. page: 1,
  58. isPage: true,
  59. list: []
  60. },{
  61. name: '待发货',
  62. loading_class: true,
  63. loading_text: '正在加载中...',
  64. page: 1,
  65. isPage: true,
  66. list: []
  67. },{
  68. name: '已完成',
  69. loading_class: true,
  70. loading_text: '正在加载中...',
  71. page: 1,
  72. isPage: true,
  73. list: []
  74. },{
  75. name: '已退单',
  76. loading_class: true,
  77. loading_text: '正在加载中...',
  78. page: 1,
  79. isPage: true,
  80. list: []
  81. }],
  82. page_size: 10,
  83. windowHeight: 0
  84. }
  85. },
  86. onLoad(){
  87. this.windowHeight = uni.getSystemInfoSync().windowHeight;
  88. },
  89. methods: {
  90. tabsChange(current){
  91. this.current = current;
  92. },
  93. swiperChange(event){
  94. this.current = event.detail.current;
  95. }
  96. }
  97. }
  98. </script>
  99. <style>
  100. page{
  101. background-color: #f6f6f6;
  102. }
  103. </style>
  104. <style lang="scss" scoped="scoped">
  105. .card{
  106. width: 100%;
  107. height: max-content;
  108. background-color: #FFFFFF;
  109. border-radius: 20rpx;
  110. padding: 0 20rpx;
  111. box-sizing: border-box;
  112. margin-bottom: 30rpx;
  113. .item{
  114. padding: 20rpx 0;
  115. box-sizing: border-box;
  116. width: 100%;
  117. border-bottom: 1rpx solid #E5E5E5;
  118. font-size: 28rpx;
  119. &:last-child{
  120. border-bottom: none;
  121. }
  122. }
  123. // 已报价,等待审核
  124. .quoted-price{
  125. color: #777777;
  126. }
  127. // 等待报价
  128. .wait{
  129. color: #1833F2;
  130. }
  131. // 已通过审核
  132. .passed{
  133. color: #0BCE5F;
  134. }
  135. // 报价被拒绝
  136. .refuse{
  137. color: #FF0000;
  138. }
  139. }
  140. </style>