solution.vue 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108
  1. <template>
  2. <div>
  3. <div class="count-list" v-if="record">
  4. <div class="count-item">总数:{{record.sum}}</div>
  5. <div class="count-item">待审核:{{record.wait_check}}</div>
  6. <div class="count-item">已通过:{{record.approve}}</div>
  7. <div class="count-item">拒绝:{{record.deny}}</div>
  8. </div>
  9. <div class="content" v-if="solutionData">
  10. <el-table :data="solutionData" height="100%" border style="width: 100%">
  11. <el-table-column prop="title" label="方案名称"></el-table-column>
  12. <el-table-column prop="login_mobile" label="联系方式"></el-table-column>
  13. <el-table-column prop="updated_at" label="入驻时间"></el-table-column>
  14. <el-table-column prop="checked_at" label="操作时间"></el-table-column>
  15. <el-table-column prop="nickname" label="客户经理"></el-table-column>
  16. <el-table-column prop="status" label="当前状态"></el-table-column>
  17. <el-table-column label="操作">
  18. <template slot-scope="scope">
  19. <el-checkbox label="1" @change="contact(scope.row.id)" name="type">联系他</el-checkbox>
  20. <el-button
  21. type="text"
  22. @click="detail(scope.row.id)"
  23. >查看详情</el-button>
  24. </template>
  25. </el-table-column>
  26. </el-table>
  27. </div>
  28. <el-pagination class="order-footer" background layout="prev, pager, next" :page-size="20" :total="Number(solutionData.total)" @current-change="handleCurrentChange"/>
  29. </div>
  30. </template>
  31. <script>
  32. export default {
  33. data() {
  34. return {
  35. page: 1,
  36. solutionData: [],
  37. form: {
  38. reason: ''
  39. },
  40. record:[],
  41. isDialogShow: false
  42. };
  43. },
  44. mounted() {
  45. this.getList();
  46. },
  47. methods: {
  48. async detail(id) {
  49. window.open(`/main/solution_detail?id=${id}`,'_self')
  50. },
  51. async getList() {
  52. const page = this.page;
  53. const size = 20;
  54. const data = {
  55. page,
  56. size
  57. };
  58. let res = await this.$post("/api/admin/kaifawu/getProviders", data);
  59. this.solutionData = res.data.list;
  60. this.record = res.data.record;
  61. },
  62. async contact(id) {
  63. const data = {
  64. id
  65. };
  66. let res = await this.$post("/api/admin/kaifawu/contact", data);
  67. this.$message({
  68. message: res.info,
  69. type: 'success'
  70. });
  71. },
  72. }
  73. };
  74. </script>
  75. <style lang="scss" scoped>
  76. .count-list {
  77. padding-bottom: 10px;
  78. display: flex;
  79. align-items: center;
  80. }
  81. .count-item {
  82. margin-right: 20px;
  83. font-size: 16px;
  84. }
  85. .content {
  86. white-space: nowrap;
  87. overflow-x: scroll;
  88. height: calc(100vh - 150px);
  89. }
  90. .btn {
  91. width: 80px;
  92. }
  93. .order-footer {
  94. margin-top: 10px;
  95. }
  96. </style>