DecListTable.vue 2.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889
  1. <template>
  2. <div class="leo-dec-list-table" v-loading="loading">
  3. <el-table :data="tableData" stripe style="width: 100%;" :height="tool.getTableHeight(true)">
  4. <el-table-column label="会员编号" prop="USER_NAME"></el-table-column>
  5. <el-table-column label="订单编号" prop="ORDER_SN"></el-table-column>
  6. <el-table-column label="注册会员" v-if="type==='ZC'">
  7. <template slot-scope="scope">
  8. {{scope.row.INSERT_USER_NAME}}<br>
  9. </template>
  10. </el-table-column>
  11. <el-table-column label="报单金额" prop="DEC_AMOUNT" v-if="type!=='OR'"></el-table-column>
  12. <el-table-column label="订货单金额" prop="ORDER_AMOUNT" v-if="type==='OR'"></el-table-column>
  13. <el-table-column label="报单BV" prop="DEC_PV" v-if="type!=='OR'"></el-table-column>
  14. <el-table-column label="订货单BV" prop="ORDER_PV" v-if="type==='OR'"></el-table-column>
  15. <el-table-column label="支付钱包">
  16. <template slot-scope="scope">
  17. {{paidType[scope.row.PAID_WALLET].title}}<br>
  18. </template>
  19. </el-table-column>
  20. <el-table-column label="返利BV" v-if="type==='OR'">
  21. <template slot-scope="scope">
  22. {{scope.row.FL_PV}}<br>
  23. </template>
  24. </el-table-column>
  25. <el-table-column label="补贴BV" v-if="type==='OR'">
  26. <template slot-scope="scope">
  27. {{scope.row.BT_PV}}<br>
  28. </template>
  29. </el-table-column>
  30. <el-table-column label="报单期数" prop="PERIOD_NUM"></el-table-column>
  31. <el-table-column label="创建时间">
  32. <template slot-scope="scope">
  33. {{tool.formatDate(scope.row.CREATED_AT)}}<br>
  34. </template>
  35. </el-table-column>
  36. </el-table>
  37. <div class="white-box-footer">
  38. <pagination :total="totalCount" :page_size="pageSize" @size-change="handleSizeChange" @current-change="handleCurrentChange"></pagination>
  39. </div>
  40. </div>
  41. </template>
  42. <script>
  43. import network from '@/utils/network'
  44. import tool from '@/utils/tool'
  45. import baseInfo from '@/utils/baseInfo'
  46. import Pagination from '@/components/Pagination'
  47. export default {
  48. name: 'leo-dec-list-table',
  49. components: {Pagination},
  50. props: {
  51. type: {
  52. type: String,
  53. default: 'ZC'
  54. },
  55. },
  56. mounted () {
  57. this.getData()
  58. },
  59. data () {
  60. return {
  61. tableData: null,
  62. loading: true,
  63. currentPage: 1,
  64. totalPages: 1,
  65. totalCount: 1,
  66. pageSize: 20,
  67. tool: tool,
  68. paidType: baseInfo.shopWalletType(),
  69. }
  70. },
  71. methods: {
  72. handleCurrentChange (page) {
  73. this.getData(page, this.pageSize)
  74. },
  75. handleSizeChange (pageSize) {
  76. this.getData(this.currentPage, pageSize)
  77. },
  78. getData (page, pageSize) {
  79. network.getPageData(this, 'finance/dec-list', page, pageSize, {decType: this.type})
  80. },
  81. }
  82. }
  83. </script>
  84. <style scoped>
  85. </style>