|
@@ -36,8 +36,9 @@ const mutations = {
|
|
state.curDragElement = curDragElement;
|
|
state.curDragElement = curDragElement;
|
|
},
|
|
},
|
|
setCurPage(state, curPageNo) {
|
|
setCurPage(state, curPageNo) {
|
|
- state.curPage = state.pages[curPageNo];
|
|
|
|
- state.curPageNo = curPageNo;
|
|
|
|
|
|
+ const pageNo = state.pages[curPageNo] ? curPageNo : 0;
|
|
|
|
+ state.curPage = state.pages[pageNo];
|
|
|
|
+ state.pageNo = pageNo;
|
|
},
|
|
},
|
|
setCurPageNo(state, curPageNo) {
|
|
setCurPageNo(state, curPageNo) {
|
|
state.curPageNo = curPageNo;
|
|
state.curPageNo = curPageNo;
|