index.vue 5.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168
  1. <template>
  2. <div class="page-container">
  3. <PageTitle title="对账结算状况" />
  4. <SearchBar :form="searchForm" :filters="filters">
  5. <template #buttons>
  6. <el-button type="danger">导出</el-button>
  7. </template>
  8. </SearchBar>
  9. <el-table :data="tableData" border style="width: 100%">
  10. <el-table-column prop="orderNo" label="订单编号" min-width="110" align="center" />
  11. <el-table-column prop="orderType" label="订单类型" min-width="90" align="center">
  12. <template #default="{ row }">{{ row.orderType || '-' }}</template>
  13. </el-table-column>
  14. <el-table-column prop="amount" label="金额" min-width="100" align="center">
  15. <template #default="{ row }">¥{{ row.amount.toLocaleString() }}</template>
  16. </el-table-column>
  17. <el-table-column prop="orderDate" label="下单日期" min-width="100" align="center" />
  18. <el-table-column prop="orderStatus" label="订单状态" min-width="90" align="center">
  19. <template #default="{ row }">
  20. <span :class="['status-tag', getOrderStatusClass(row.orderStatus)]">{{ row.orderStatus }}</span>
  21. </template>
  22. </el-table-column>
  23. <el-table-column prop="billStatus" label="对账状态" min-width="90" align="center">
  24. <template #default="{ row }">{{ row.billStatus || '-' }}</template>
  25. </el-table-column>
  26. <el-table-column prop="invoiceStatus" label="开票状态" min-width="90" align="center">
  27. <template #default="{ row }">
  28. <span :class="['status-tag', getInvoiceStatusClass(row.invoiceStatus)]">{{ row.invoiceStatus }}</span>
  29. </template>
  30. </el-table-column>
  31. <el-table-column prop="settleStatus" label="结算状态" min-width="90" align="center">
  32. <template #default="{ row }">
  33. <span :style="{ color: row.settleStatus === '已结算' ? '#67c23a' : '' }">{{ row.settleStatus }}</span>
  34. </template>
  35. </el-table-column>
  36. </el-table>
  37. <TablePagination v-model:page="pagination.page" v-model:pageSize="pagination.pageSize" :total="pagination.total" />
  38. </div>
  39. </template>
  40. <script setup lang="ts">
  41. import { reactive, ref } from 'vue';
  42. import { PageTitle, SearchBar, TablePagination } from '@/components';
  43. import { BILL_STATUS_OPTIONS, INVOICE_STATUS_OPTIONS, SETTLE_STATUS_OPTIONS } from '@/constants/status';
  44. import { getOrderStatusClass, getInvoiceStatusClass } from '@/utils/status';
  45. const searchForm = reactive({
  46. keyword: '',
  47. dateRange: [],
  48. billStatus: '',
  49. invoiceStatus: '',
  50. settleStatus: ''
  51. });
  52. const filters = [
  53. { field: 'billStatus', label: '对账状态', options: BILL_STATUS_OPTIONS },
  54. { field: 'invoiceStatus', label: '开票状态', options: INVOICE_STATUS_OPTIONS },
  55. { field: 'settleStatus', label: '结算状态', options: SETTLE_STATUS_OPTIONS }
  56. ];
  57. const pagination = reactive({ page: 1, pageSize: 10, total: 100 });
  58. const tableData = ref([
  59. {
  60. orderNo: '232323232',
  61. orderType: '普通订单',
  62. amount: 2115.97,
  63. orderDate: '2025-11-22',
  64. orderStatus: '运输中',
  65. billStatus: '已对账',
  66. invoiceStatus: '已付款',
  67. settleStatus: '已结算'
  68. },
  69. {
  70. orderNo: '2323412123',
  71. orderType: '普通订单',
  72. amount: 4476.12,
  73. orderDate: '2025-12-09',
  74. orderStatus: '待发货',
  75. billStatus: '未对账',
  76. invoiceStatus: '待开票',
  77. settleStatus: '未结算'
  78. },
  79. {
  80. orderNo: '4566784543',
  81. orderType: '协议订单',
  82. amount: 7751.34,
  83. orderDate: '2025-11-21',
  84. orderStatus: '已收货',
  85. billStatus: '已对账',
  86. invoiceStatus: '已开票',
  87. settleStatus: '已结算'
  88. },
  89. {
  90. orderNo: '2356565654',
  91. orderType: '普通订单',
  92. amount: 7936.37,
  93. orderDate: '2025-11-27',
  94. orderStatus: '运输中',
  95. billStatus: '未对账',
  96. invoiceStatus: '已付款',
  97. settleStatus: '未结算'
  98. },
  99. {
  100. orderNo: '2323412123',
  101. orderType: '协议订单',
  102. amount: 3931.45,
  103. orderDate: '2025-12-11',
  104. orderStatus: '待发货',
  105. billStatus: '未对账',
  106. invoiceStatus: '待开票',
  107. settleStatus: '未结算'
  108. },
  109. {
  110. orderNo: '2323232323',
  111. orderType: '普通订单',
  112. amount: 6132.75,
  113. orderDate: '2025-11-27',
  114. orderStatus: '已收货',
  115. billStatus: '已对账',
  116. invoiceStatus: '已开票',
  117. settleStatus: '已结算'
  118. },
  119. {
  120. orderNo: '2356565654',
  121. orderType: '普通订单',
  122. amount: 3189.56,
  123. orderDate: '2025-11-25',
  124. orderStatus: '已收货',
  125. billStatus: '已对账',
  126. invoiceStatus: '已开票',
  127. settleStatus: '已结算'
  128. },
  129. {
  130. orderNo: '2323232323',
  131. orderType: '协议订单',
  132. amount: 993.66,
  133. orderDate: '2025-11-20',
  134. orderStatus: '运输中',
  135. billStatus: '未对账',
  136. invoiceStatus: '已付款',
  137. settleStatus: '未结算'
  138. },
  139. {
  140. orderNo: '2323412123',
  141. orderType: '普通订单',
  142. amount: 2763.35,
  143. orderDate: '2025-11-17',
  144. orderStatus: '待发货',
  145. billStatus: '未对账',
  146. invoiceStatus: '待开票',
  147. settleStatus: '未结算'
  148. },
  149. {
  150. orderNo: '2323232323',
  151. orderType: '协议订单',
  152. amount: 9286.45,
  153. orderDate: '2025-12-05',
  154. orderStatus: '已收货',
  155. billStatus: '已对账',
  156. invoiceStatus: '已开票',
  157. settleStatus: '已结算'
  158. }
  159. ]);
  160. </script>