arrearsReport.vue 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142
  1. <!-- 欠费统计 -->
  2. <template>
  3. <view class="container">
  4. <view class="table">
  5. <view class="table-date" v-if="currentDate">{{ currentDate.join(' 至 ') }}</view>
  6. <view class="table-box">
  7. <uni-table emptyText="暂无更多数据">
  8. <!-- 表头行 -->
  9. <uni-tr>
  10. <uni-th class="table-box-th" align="center" v-for="(item, index) in tableTh" :key="index" :width="item.width || ''">{{ item.field }}
  11. </uni-th>
  12. </uni-tr>
  13. <!-- 表格数据行 -->
  14. <uni-tr v-for="(item, index) in tableData.list" :key="index">
  15. <uni-td class="table-box-td" align="center">{{ item.road }}</uni-td>
  16. <uni-td class="table-box-td" align="center">{{ item.road }}</uni-td>
  17. <uni-td class="table-box-td" align="center">{{ item.num }}</uni-td>
  18. <uni-td class="table-box-td" align="center">{{ item.really }}</uni-td>
  19. <uni-td class="table-box-td" align="center">{{ item.really }}</uni-td>
  20. </uni-tr>
  21. </uni-table>
  22. </view>
  23. <view class="table-pagination">
  24. <uni-pagination show-icon="true" :total="tableData.total" :current="tableData.current"></uni-pagination>
  25. </view>
  26. </view>
  27. <view class="total">
  28. <view>
  29. 欠费次数<text>{{ totalData.num }}</text>次,欠费金额<text>{{ totalData.really }}</text>元
  30. </view>
  31. </view>
  32. </view>
  33. </template>
  34. <script>
  35. export default {
  36. props: {
  37. currentDate: {
  38. type: Array,
  39. default: []
  40. },
  41. tableTh: {
  42. type: Array,
  43. default: () => {
  44. return [
  45. { field: '车牌号', width: 120 },
  46. { field: '车主姓名', width: 120 },
  47. { field: '联系方式', width: 80 },
  48. { field: '欠费次数(次)', width: 80 },
  49. { field: '欠费金额(元)', width: 80 }
  50. ]
  51. }
  52. },
  53. tableData: {
  54. type: Object,
  55. default: () => {
  56. return {
  57. current: 1,
  58. total: 30,
  59. list: [{
  60. num: 1001,
  61. name: 'xxx',
  62. road: '金科路',
  63. really: 80
  64. },
  65. {
  66. num: 1001,
  67. name: 'xxx',
  68. road: '金科路',
  69. should: 100,
  70. really: 80
  71. },
  72. {
  73. num: 1001,
  74. name: 'xxx',
  75. road: '金科路',
  76. should: 100,
  77. really: 80
  78. },
  79. {
  80. num: 1001,
  81. name: 'xxx',
  82. road: '金科路',
  83. should: 100,
  84. really: 80
  85. },
  86. {
  87. num: 1001,
  88. name: 'xxx',
  89. road: '金科路',
  90. should: 100,
  91. really: 80
  92. },
  93. {
  94. num: 1001,
  95. name: 'xxx',
  96. road: '金科路',
  97. should: 100,
  98. really: 80
  99. },
  100. {
  101. num: 1001,
  102. name: 'xxx',
  103. road: '金科路',
  104. should: 100,
  105. really: 80
  106. },
  107. {
  108. num: 1001,
  109. name: 'xxx',
  110. road: '金科路',
  111. should: 100,
  112. really: 80
  113. },
  114. {
  115. num: 1001,
  116. name: 'xxx',
  117. road: '金科路',
  118. should: 100,
  119. really: 80
  120. }
  121. ]
  122. }
  123. }
  124. },
  125. totalData: {
  126. type: Object,
  127. default: () => {
  128. return {
  129. num: 100,
  130. really: 80
  131. }
  132. }
  133. }
  134. }
  135. }
  136. </script>
  137. <style lang="scss" scoped>
  138. @import './report.scss';
  139. </style>