index.vue 3.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186
  1. <template>
  2. <view class="content">
  3. <uHeader ref="toRefresh" :userinfo="userinfo" />
  4. <!-- 卡片 -->
  5. <view class="card">
  6. <view class="title">
  7. 待办事项
  8. </view>
  9. <view class="row">
  10. <view class="col" @click="goToReFund(1)">
  11. <view class="item-title">
  12. 待结算(笔)
  13. </view>
  14. <view class="item-num">
  15. {{data.settle}}
  16. </view>
  17. </view>
  18. <view class="col" @click="goToReFund(2)">
  19. <view class="item-title">
  20. 待处理的反馈建议(条)
  21. </view>
  22. <view class="item-num">
  23. {{data.feedback}}
  24. </view>
  25. </view>
  26. </view>
  27. <view class="row">
  28. <view class="col" @click="goToReFund(3)">
  29. <view class="item-title">
  30. 待处理的退款(笔)
  31. </view>
  32. <view class="item-num">
  33. {{data.refund}}
  34. </view>
  35. </view>
  36. <view class="col" @click="goToReFund(4)">
  37. <view class="item-title">
  38. 售后管理(条)
  39. </view>
  40. <view class="item-num">
  41. {{data.service}}
  42. </view>
  43. </view>
  44. </view>
  45. </view>
  46. <view class="card">
  47. <view class="title">
  48. 资金流水
  49. </view>
  50. <view class="row">
  51. <view class="col" @click="goToTurnOver(1)">
  52. <view class="item-title">
  53. 今日营业额(元)
  54. </view>
  55. <view class="item-num">
  56. {{data.today_turnover}}
  57. </view>
  58. </view>
  59. <view class="col" @click="goToTurnOver(2)">
  60. <view class="item-title">
  61. 今日结算金额(元)
  62. </view>
  63. <view class="item-num">
  64. {{data.today_settled}}
  65. </view>
  66. </view>
  67. </view>
  68. <view class="row">
  69. <view class="col" @click="goToTurnOver(3)">
  70. <view class="item-title">
  71. 今日盈利明细(元)
  72. </view>
  73. <view class="item-num">
  74. {{data.today_profit}}
  75. </view>
  76. </view>
  77. </view>
  78. </view>
  79. </view>
  80. </template>
  81. <script>
  82. import uHeader from '../../components/u-header.vue'
  83. export default {
  84. components: {
  85. uHeader
  86. },
  87. data() {
  88. return {
  89. userinfo: {},
  90. // 表格数据
  91. data: {},
  92. }
  93. },
  94. onShow() {
  95. this.getDo()
  96. },
  97. methods: {
  98. // 获取代办事项信息
  99. getDo() {
  100. this.request("/admin_order/do", {}, "GET").then(res => {
  101. console.log(res)
  102. if (res.code === 1) {
  103. this.data = res.data
  104. }
  105. })
  106. },
  107. // 点击前往营业额
  108. goToTurnOver(type) {
  109. if(type === 3){
  110. uni.navigateTo({
  111. url:"/pages/turnover/info"
  112. })
  113. }
  114. uni.navigateTo({
  115. url: "/pages/turnover/turnover?type=" + type
  116. })
  117. },
  118. // 前往退款
  119. goToReFund(type) {
  120. uni.navigateTo({
  121. url: "/pages/refund/refund?type=" + type
  122. })
  123. }
  124. }
  125. }
  126. </script>
  127. <style lang="scss">
  128. .content {
  129. display: flex;
  130. flex-direction: column;
  131. align-items: center;
  132. justify-content: flex-start;
  133. z-index: 99;
  134. background-color: #F8F8F8;
  135. min-height: 100vh;
  136. padding-top: 180rpx;
  137. .card {
  138. width: 90%;
  139. border-radius: 20rpx;
  140. padding: 20rpx;
  141. background-color: #FFFFFF;
  142. margin-bottom: 60rpx;
  143. .title {
  144. font-size: 15px;
  145. font-family: PingFang SC;
  146. font-weight: 500;
  147. line-height: 21px;
  148. color: #000000;
  149. text-align: center;
  150. }
  151. .row {
  152. display: flex;
  153. flex-direction: row;
  154. align-items: center;
  155. justify-content: space-between;
  156. margin-top: 40rpx;
  157. .col {
  158. width: 50%;
  159. .item-title {
  160. font-size: 13px;
  161. font-family: PingFang SC;
  162. font-weight: 400;
  163. line-height: 20px;
  164. color: #707070;
  165. }
  166. .item-num {
  167. font-size: 20px;
  168. font-family: PingFang SC;
  169. font-weight: 600;
  170. line-height: 28px;
  171. color: #111111;
  172. }
  173. }
  174. }
  175. }
  176. }
  177. </style>