pregnancyTestLog.vue 4.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142
  1. <template>
  2. <div class="pregnancyTestLog">
  3. <h2 style="margin-bottom: 20px;padding-bottom:7px;border-bottom:2px solid #ddd">断奶信息</h2>
  4. <header id="header">
  5. <el-row type="flex" :gutter="20">
  6. <el-col :span="4">
  7. <el-input v-model="value" placeholder="请选择"/>
  8. </el-col>
  9. <el-col :span="4">
  10. <el-button type="primary">查找</el-button>
  11. </el-col>
  12. <el-col :span="4">
  13. <el-button type="primary">新增</el-button>
  14. </el-col>
  15. </el-row>
  16. </header>
  17. <section>
  18. <article class="table">
  19. <el-table
  20. ref="multipleTable"
  21. :data="tableData"
  22. tooltip-effect="dark"
  23. style="width: 100%"
  24. @selection-change="handleSelectionChange"
  25. >
  26. <el-table-column prop="a" label="种母羊编码"></el-table-column>
  27. <el-table-column prop="b" label="任检时间"></el-table-column>
  28. <el-table-column prop="c" label="状态"></el-table-column>
  29. <el-table-column prop="d" label="当前位置"></el-table-column>
  30. <el-table-column prop="e" label="怀胎个数"></el-table-column>
  31. <el-table-column prop="f" label="备注"></el-table-column>
  32. <!-- <el-table-column label="操作" width="150">
  33. <template slot-scope="scope">
  34. <el-button @click="edit(scope.row)" type="text" size="small">编辑</el-button>
  35. <el-popconfirm title="是否删除此设备的信息?" @onConfirm="del(scope.row)">
  36. <el-button slot="reference" type="text" size="small">删除</el-button>
  37. </el-popconfirm>
  38. </template>
  39. </el-table-column> -->
  40. </el-table>
  41. <el-row type="flex" justify="end">
  42. <el-col :span="8" class="pagination">
  43. <el-pagination
  44. @current-change="pageChange"
  45. background
  46. layout="prev, pager, next"
  47. :page-count="10"
  48. ></el-pagination>
  49. </el-col>
  50. </el-row>
  51. </article>
  52. </section>
  53. </div>
  54. </template>
  55. <script>
  56. const pageSize = 10
  57. const tableData = [
  58. {
  59. a: "15463",
  60. b: "胴体",
  61. c: "2020-07-14",
  62. d: "49kg",
  63. e: "48kg",
  64. f: "1.6%",
  65. g: "张小刚",
  66. },
  67. {
  68. a: "15463",
  69. b: "带骨羊前腿",
  70. c: "2020-07-14",
  71. d: "49kg",
  72. e: "48kg",
  73. f: "1.6%",
  74. g: "张小刚",
  75. },
  76. {
  77. a: "15463",
  78. b: "羔羊肉卷",
  79. c: "2020-07-14",
  80. d: "49kg",
  81. e: "48kg",
  82. f: "1.6%",
  83. g: "张小刚",
  84. },
  85. {
  86. a: "15463",
  87. b: "胴体",
  88. c: "2020-07-14",
  89. d: "49kg",
  90. e: "48kg",
  91. f: "1.6%",
  92. g: "张小刚",
  93. },
  94. {
  95. a: "15463",
  96. b: "羔羊肉卷",
  97. c: "2020-07-14",
  98. d: "49kg",
  99. e: "48kg",
  100. f: "1.6%",
  101. g: "张小刚",
  102. },
  103. ]
  104. export default {
  105. data() {
  106. return {
  107. value: "",
  108. multipleSelection: [],
  109. page: 1,
  110. tableData
  111. };
  112. },
  113. created() {},
  114. methods: {
  115. handleSelectionChange(val) {
  116. this.multipleSelection = val;
  117. },
  118. edit(row) {},
  119. del(row) {},
  120. pageChange(p) {
  121. console.log(p);
  122. }
  123. }
  124. };
  125. </script>
  126. <style lang="scss" scoped>
  127. #header {
  128. margin-bottom: 15px;
  129. }
  130. .table {
  131. .pagination {
  132. margin-top: 20px;
  133. }
  134. }
  135. </style>