<template>
    <el-pagination
        class="adm-pagination"
        :current-page="currentPage"
        :page-sizes="paginationList.sizes"
        :page-size="paginationList.size"
        layout="total,sizes,prev,pager,next,jumper"
        :total="paginationList.total"
    />
</template>

<script lang="ts">
// 当前页，总数，范围
interface Pagination {
    size: number
    total: number
    sizes: []
}

import { Vue, Component, Emit, Prop } from "vue-property-decorator";
@Component({
    name: 'adm-pagination'
})
export default class extends Vue {
    @Prop({ type: Object, default: {} }) paginationList ?: Pagination

    @Emit('currentPage')
    currentPage(val: number) {
        return val
    }
}
</script>

<style scoped>

</style>
