index.vue 3.3KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126
  1. <template>
  2. <div class="subPage">
  3. <div class="list flex-h">
  4. <div class="flex-item">
  5. <div style="text-align:right;margin: 20px 0 0;border:none;">
  6. <el-button
  7. size="mini"
  8. type="warning"
  9. @click="reback">返回</el-button>
  10. </div>
  11. <div>
  12. <el-table
  13. :data="coursesList"
  14. stripe
  15. style="width: 100%">
  16. <el-table-column
  17. prop="CaseName"
  18. label="所在案场">
  19. </el-table-column>
  20. <el-table-column
  21. prop="LocationId"
  22. label="课程类别">
  23. </el-table-column>
  24. <el-table-column
  25. prop="CourseName"
  26. label="课程名称">
  27. </el-table-column>
  28. <el-table-column
  29. prop="DetailName"
  30. label="课时名称">
  31. </el-table-column>
  32. <el-table-column
  33. prop="BeginDate"
  34. label="课程开始时间">
  35. </el-table-column>
  36. <el-table-column
  37. prop="EndDate"
  38. label="课程结束时间">
  39. </el-table-column>
  40. <el-table-column
  41. label="操作">
  42. <template slot-scope="scope">
  43. <el-button
  44. size="mini"
  45. type="success"
  46. @click="check(scope.row)">核销</el-button>
  47. </template>
  48. </el-table-column>
  49. </el-table>
  50. </div>
  51. <span class="noData">今日暂无可核销的课程</span>
  52. </div>
  53. </div>
  54. <el-dialog
  55. title="提示"
  56. :visible.sync="centerDialogVisible"
  57. width="300px"
  58. center>
  59. <span style="width:100%;display:block;text-align:center;margin:20px 0;">确认核销此课程?</span>
  60. <span slot="footer" class="dialog-footer">
  61. <el-button @click="centerDialogVisible = false">取 消</el-button>
  62. <el-button type="primary" @click="centerDialogVisible = false">确 定</el-button>
  63. </span>
  64. </el-dialog>
  65. </div>
  66. </template>
  67. <script>
  68. export default {
  69. name: '',
  70. data () {
  71. return {
  72. centerDialogVisible: false,
  73. coursesList: [{
  74. CaseName: 'xxx',
  75. LocationId: 'xxx',
  76. CourseName: 'xxx',
  77. DetailName: 'xxx',
  78. BeginDate: 'xxx',
  79. EndDate: 'xxx',
  80. }],
  81. }
  82. },
  83. mounted () {
  84. this.$nextTick(function () { })
  85. },
  86. methods: {
  87. check (item) { // 核销
  88. this.centerDialogVisible = true
  89. },
  90. reback () { // 返回
  91. this.$router.push({name: 'qrcodeVerification'})
  92. },
  93. }
  94. }
  95. </script>
  96. <!-- Add "scoped" attribute to limit CSS to this component only -->
  97. <style lang="scss" scoped>
  98. .subPage {
  99. .list {
  100. > div {
  101. margin: 0 20px;
  102. > div {
  103. width: 100%;
  104. position: relative;
  105. overflow: hidden;
  106. box-sizing: border-box;
  107. border: 1px solid #eee;
  108. border-bottom: none;
  109. margin-top: 20px;
  110. }
  111. }
  112. }
  113. .noData{
  114. width: 100%;
  115. display: block;
  116. line-height: 40px;
  117. font-size: 30px;
  118. color: #ccc;
  119. text-align: center;
  120. margin: 40px auto 0;
  121. }
  122. }
  123. </style>