diff options
author | Phil Hughes <me@iamphill.com> | 2017-04-20 14:15:39 +0100 |
---|---|---|
committer | Phil Hughes <me@iamphill.com> | 2017-04-20 14:15:39 +0100 |
commit | b7b5bd4a49a212f41f08be98997c25c0ce530f97 (patch) | |
tree | 72e7b32423adf742a9d8dcbfe2608fec86be0378 /app/assets/javascripts/boards/models | |
parent | 7d16537cac7eb808d8d18cd0b89475db4e4eeaaa (diff) | |
parent | 7ceb0efc6c6016e055ec6862759ff5f442551c4a (diff) | |
download | gitlab-ce-b7b5bd4a49a212f41f08be98997c25c0ce530f97.tar.gz |
Merge remote-tracking branch 'origin/28433-internationalise-cycle-analytics-page' into js-translations
Diffstat (limited to 'app/assets/javascripts/boards/models')
-rw-r--r-- | app/assets/javascripts/boards/models/list.js | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/app/assets/javascripts/boards/models/list.js b/app/assets/javascripts/boards/models/list.js index 91e5fb2a666..f2b79a88a4a 100644 --- a/app/assets/javascripts/boards/models/list.js +++ b/app/assets/javascripts/boards/models/list.js @@ -3,6 +3,8 @@ /* global ListLabel */ import queryData from '../utils/query_data'; +const PER_PAGE = 20; + class List { constructor (obj) { this.id = obj.id; @@ -58,7 +60,9 @@ class List { nextPage () { if (this.issuesSize > this.issues.length) { - this.page += 1; + if (this.issues.length / PER_PAGE >= 1) { + this.page += 1; + } return this.getIssues(false); } @@ -145,10 +149,7 @@ class List { } updateIssueLabel(issue, listFrom, moveBeforeIid, moveAfterIid) { - gl.boardService.moveIssue(issue.id, listFrom.id, this.id, moveBeforeIid, moveAfterIid) - .then(() => { - listFrom.getIssues(false); - }); + gl.boardService.moveIssue(issue.id, listFrom.id, this.id, moveBeforeIid, moveAfterIid); } findIssue (id) { |