Can filter by author & assignee
This commit is contained in:
parent
d06e20b263
commit
fce8ee3e54
4 changed files with 17 additions and 6 deletions
|
@ -14,6 +14,13 @@
|
|||
this.board.filters = this.getFilterData();
|
||||
this.board.getIssues(true);
|
||||
}
|
||||
},
|
||||
'filters': {
|
||||
handler: function () {
|
||||
this.board.filters = this.getFilterData();
|
||||
this.board.getIssues(true);
|
||||
},
|
||||
deep: true
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
|
|
|
@ -11,8 +11,10 @@ $(() => {
|
|||
});
|
||||
},
|
||||
renderRow: (label) => {
|
||||
if (BoardsStore.findList('title', label.title)) return;
|
||||
const $li = $('<li />'),
|
||||
const isHidden = BoardsStore.findList('title', label.title),
|
||||
$li = $('<li />', {
|
||||
class: (isHidden ? 'hidden' : '')
|
||||
}),
|
||||
$a = $('<a />', {
|
||||
text: label.title,
|
||||
href: '#'
|
||||
|
|
|
@ -3,9 +3,9 @@
|
|||
state: {
|
||||
lists: [],
|
||||
filters: {
|
||||
author: {},
|
||||
assignee: {},
|
||||
milestone: {},
|
||||
author_id: null,
|
||||
assignee_id: null,
|
||||
milestone_id: null,
|
||||
label: []
|
||||
}
|
||||
},
|
||||
|
|
|
@ -149,7 +149,9 @@
|
|||
if ($dropdown.hasClass('js-filter-bulk-update')) {
|
||||
return;
|
||||
}
|
||||
if ($dropdown.hasClass('js-filter-submit') && (isIssueIndex || isMRIndex)) {
|
||||
if (page === 'projects:boards:show') {
|
||||
BoardsStore.state.filters[$dropdown.data('field-name')] = user.id;
|
||||
} else if ($dropdown.hasClass('js-filter-submit') && (isIssueIndex || isMRIndex)) {
|
||||
selectedId = user.id;
|
||||
return Issuable.filterResults($dropdown.closest('form'));
|
||||
} else if ($dropdown.hasClass('js-filter-submit')) {
|
||||
|
|
Loading…
Reference in a new issue