Skip to content

Commit

Permalink
Pagination: update pager value when page size changes (#10157)
Browse files Browse the repository at this point in the history
  • Loading branch information
Leopoldthecoder authored Mar 14, 2018
1 parent 8eaf600 commit 5797325
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions packages/pagination/src/pagination.js
Original file line number Diff line number Diff line change
Expand Up @@ -211,6 +211,14 @@ export default {

components: { ElInput },

watch: {
'$parent.internalPageSize'() {
this.$nextTick(() => {
this.$refs.input.$el.querySelector('input').value = this.$parent.internalCurrentPage;
});
}
},

methods: {
handleFocus(event) {
this.oldValue = event.target.value;
Expand Down

0 comments on commit 5797325

Please sign in to comment.