diff options
author | Phil Hughes <me@iamphill.com> | 2016-11-24 13:38:24 +0300 |
---|---|---|
committer | Phil Hughes <me@iamphill.com> | 2016-11-24 13:38:24 +0300 |
commit | 18a54116e2f1d2ac88d03ad7ed48213dab580854 (patch) | |
tree | a009817678691421f28fbf650e917a21367c7554 | |
parent | 058c652904b13cea73e92615776f29fd1a8a1ded (diff) |
Fixed dragging issue moving wrong issue after multiple drags of issue
-rw-r--r-- | app/assets/javascripts/boards/components/board_list.js.es6 | 2 | ||||
-rw-r--r-- | app/views/projects/boards/components/_card.html.haml | 1 |
2 files changed, 2 insertions, 1 deletions
diff --git a/app/assets/javascripts/boards/components/board_list.js.es6 b/app/assets/javascripts/boards/components/board_list.js.es6 index 8996ca438a6..48e37fa64ea 100644 --- a/app/assets/javascripts/boards/components/board_list.js.es6 +++ b/app/assets/javascripts/boards/components/board_list.js.es6 @@ -88,8 +88,8 @@ const card = this.$refs.issue[e.oldIndex]; card.showDetail = false; - Store.moving.issue = card.issue; Store.moving.list = card.list; + Store.moving.issue = Store.moving.list.findIssue(+e.item.dataset.issueId); gl.issueBoards.onStart(); }, diff --git a/app/views/projects/boards/components/_card.html.haml b/app/views/projects/boards/components/_card.html.haml index 34effac17b2..1f31496e73f 100644 --- a/app/views/projects/boards/components/_card.html.haml +++ b/app/views/projects/boards/components/_card.html.haml @@ -1,5 +1,6 @@ %li.card{ ":class" => '{ "user-can-drag": !disabled && issue.id, "is-disabled": disabled || !issue.id, "is-active": issueDetailVisible }', ":index" => "index", + ":data-issue-id" => "issue.id", "@mousedown" => "mouseDown", "@mousemove" => "mouseMove", "@mouseup" => "showIssue($event)" } |