diff options
author | Phil Hughes <me@iamphill.com> | 2017-04-13 16:33:19 +0100 |
---|---|---|
committer | Phil Hughes <me@iamphill.com> | 2017-04-13 16:33:19 +0100 |
commit | c922b846fee750dae855b1811d83e27f95b6dcec (patch) | |
tree | 03cb3cbbc39800de8da2787e583cd06a5f9cdbbc /app/assets | |
parent | d7a527163b64fa38e46fc6195fef2f5d93e47d07 (diff) | |
download | gitlab-ce-c922b846fee750dae855b1811d83e27f95b6dcec.tar.gz |
Only increase the page number for boards when we need to
Closes #30902
Diffstat (limited to 'app/assets')
-rw-r--r-- | app/assets/javascripts/boards/models/list.js | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/app/assets/javascripts/boards/models/list.js b/app/assets/javascripts/boards/models/list.js index 91e5fb2a666..d83006ebe1a 100644 --- a/app/assets/javascripts/boards/models/list.js +++ b/app/assets/javascripts/boards/models/list.js @@ -58,7 +58,9 @@ class List { nextPage () { if (this.issuesSize > this.issues.length) { - this.page += 1; + if (this.issues.length / 20 >= 1) { + this.page += 1; + } return this.getIssues(false); } @@ -145,10 +147,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) { |