Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Tatuya Kamada
gitlab-ce
Commits
83b4ba28
Commit
83b4ba28
authored
Aug 04, 2016
by
Phil Hughes
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Can move between lists
Currently a bug exists were moving into done does not remove from all
parent
a3e52ef9
Changes
7
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
25 additions
and
3 deletions
+25
-3
app/assets/javascripts/boards/components/board_list.js.es6
app/assets/javascripts/boards/components/board_list.js.es6
+2
-1
app/assets/javascripts/boards/models/issue.js.es6
app/assets/javascripts/boards/models/issue.js.es6
+1
-1
app/assets/javascripts/boards/models/list.js.es6
app/assets/javascripts/boards/models/list.js.es6
+2
-0
app/assets/javascripts/boards/services/board_service.js.es6
app/assets/javascripts/boards/services/board_service.js.es6
+10
-0
app/assets/javascripts/boards/stores/boards_store.js.es6
app/assets/javascripts/boards/stores/boards_store.js.es6
+2
-0
app/assets/stylesheets/pages/boards.scss
app/assets/stylesheets/pages/boards.scss
+5
-0
app/views/projects/boards/components/_board.html.haml
app/views/projects/boards/components/_board.html.haml
+3
-1
No files found.
app/assets/javascripts/boards/components/board_list.js.es6
View file @
83b4ba28
...
@@ -5,7 +5,8 @@
...
@@ -5,7 +5,8 @@
boardId: [Number, String],
boardId: [Number, String],
filters: Object,
filters: Object,
issues: Array,
issues: Array,
query: String
query: String,
loading: Boolean
},
},
data: () => {
data: () => {
return {
return {
...
...
app/assets/javascripts/boards/models/issue.js.es6
View file @
83b4ba28
class Issue {
class Issue {
constructor (obj) {
constructor (obj) {
this.id = obj.id;
this.id = obj.i
i
d;
this.title = obj.title;
this.title = obj.title;
this.labels = [];
this.labels = [];
...
...
app/assets/javascripts/boards/models/list.js.es6
View file @
83b4ba28
...
@@ -11,9 +11,11 @@ class List {
...
@@ -11,9 +11,11 @@ class List {
}
}
if (this.type !== 'blank') {
if (this.type !== 'blank') {
this.loading = true;
service.getIssuesForList(this.id)
service.getIssuesForList(this.id)
.then((resp) => {
.then((resp) => {
const data = resp.json();
const data = resp.json();
this.loading = false;
data.forEach((issue) => {
data.forEach((issue) => {
this.issues.push(new Issue(issue));
this.issues.push(new Issue(issue));
...
...
app/assets/javascripts/boards/services/board_service.js.es6
View file @
83b4ba28
...
@@ -4,6 +4,7 @@ class BoardService {
...
@@ -4,6 +4,7 @@ class BoardService {
this.lists = Vue.resource(`${root}{/id}.json`, {});
this.lists = Vue.resource(`${root}{/id}.json`, {});
this.list = Vue.resource(`${root}/lists{/id}.json`, {});
this.list = Vue.resource(`${root}/lists{/id}.json`, {});
this.issue = Vue.resource(`${root}/issues{/id}.json`, {});
this.issues = Vue.resource(`${root}/lists{/id}/issues.json`, {});
this.issues = Vue.resource(`${root}/lists{/id}/issues.json`, {});
}
}
...
@@ -47,4 +48,13 @@ class BoardService {
...
@@ -47,4 +48,13 @@ class BoardService {
return this.issues.get({ id });
return this.issues.get({ id });
}
}
moveIssue (id, from, to) {
return this.issue.update({ id }, {
issue: {
from,
to
}
});
}
};
};
app/assets/javascripts/boards/stores/boards_store.js.es6
View file @
83b4ba28
...
@@ -118,6 +118,8 @@
...
@@ -118,6 +118,8 @@
list.removeIssue(issue);
list.removeIssue(issue);
});
});
}
}
service.moveIssue(issue.id, listFrom.id, listTo.id);
},
},
getListsForIssue: function (issue) {
getListsForIssue: function (issue) {
return _.filter(this.state.lists, (list) => {
return _.filter(this.state.lists, (list) => {
...
...
app/assets/stylesheets/pages/boards.scss
View file @
83b4ba28
...
@@ -188,6 +188,11 @@
...
@@ -188,6 +188,11 @@
overflow
:
scroll
;
overflow
:
scroll
;
}
}
.board-list-loading
{
margin-top
:
10px
;
font-size
:
26px
;
}
.is-ghost
{
.is-ghost
{
opacity
:
0
;
opacity
:
0
;
}
}
...
...
app/views/projects/boards/components/_board.html.haml
View file @
83b4ba28
...
@@ -14,7 +14,9 @@
...
@@ -14,7 +14,9 @@
=
icon
(
"search"
,
class:
"board-search-icon"
,
"v-show"
=>
"!query"
)
=
icon
(
"search"
,
class:
"board-search-icon"
,
"v-show"
=>
"!query"
)
%button
.board-search-clear-btn
{
type:
"button"
,
role:
"button"
,
"aria-label"
=>
"Clear search"
,
"@click"
=>
"clearSearch"
,
"v-show"
=>
"query"
}
%button
.board-search-clear-btn
{
type:
"button"
,
role:
"button"
,
"aria-label"
=>
"Clear search"
,
"@click"
=>
"clearSearch"
,
"v-show"
=>
"query"
}
=
icon
(
"times"
,
class:
"board-search-clear"
)
=
icon
(
"times"
,
class:
"board-search-clear"
)
%board-list
{
"inline-template"
=>
true
,
"v-if"
=>
"board.id != 'blank'"
,
":board-id"
=>
"board.id"
,
":issues"
=>
"board.issues"
,
":disabled"
=>
"#{current_user.nil?}"
,
":query"
=>
"query"
,
":filters"
=>
"filters"
}
%board-list
{
"inline-template"
=>
true
,
"v-if"
=>
"board.id != 'blank'"
,
":board-id"
=>
"board.id"
,
":issues"
=>
"board.issues"
,
":disabled"
=>
"#{current_user.nil?}"
,
":query"
=>
"query"
,
":filters"
=>
"filters"
,
":loading"
=>
"board.loading"
}
.board-list-loading.text-center
{
"v-if"
=>
"loading"
}
=
icon
(
"spinner spin"
)
%ul
.board-list
{
"v-el:list"
=>
true
,
":data-board"
=>
"boardId"
}
%ul
.board-list
{
"v-el:list"
=>
true
,
":data-board"
=>
"boardId"
}
=
render
"projects/boards/components/card"
=
render
"projects/boards/components/card"
=
render
"projects/boards/components/blank_state"
=
render
"projects/boards/components/blank_state"
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment