pagination.vue 811 B

123456789101112131415161718192021222324252627282930313233343536373839
  1. <!--
  2. * @Author : yuanrunwei
  3. * @Date : 2021-11-01 18:11:59
  4. * @LastEditors : yuanrunwei
  5. * @LastEditTime : 2021-11-02 14:27:11
  6. * @FilePath : \spfm-front\src\pages\main\dataConfig\components\pagination.vue
  7. -->
  8. <template>
  9. <el-pagination
  10. class="simple-pagination"
  11. @current-change="handleChange"
  12. layout="prev, pager, next"
  13. background
  14. :current-page="page"
  15. :total="total"
  16. >
  17. </el-pagination>
  18. </template>
  19. <script>
  20. export default {
  21. props: {
  22. page: {
  23. type: Number,
  24. default: 0
  25. },
  26. total: {
  27. type: Number,
  28. default: 0
  29. }
  30. },
  31. data: () => ({}),
  32. methods: {
  33. handleChange(page) {
  34. this.$emit("change", page);
  35. }
  36. }
  37. };
  38. </script>