new filter: unassigned cards
Signed-off-by: Jakob Röhrl <jakob.roehrl@web.de>
This commit is contained in:
@@ -32,9 +32,10 @@ export default {
|
||||
getters: {
|
||||
cardsByStack: (state, getters, rootState) => (id) => {
|
||||
return state.cards.filter((card) => {
|
||||
const { tags, users, due } = rootState.filter
|
||||
const { tags, users, due, unassigned } = rootState.filter
|
||||
let allTagsMatch = true
|
||||
let allUsersMatch = true
|
||||
let allUnassigned = true
|
||||
|
||||
if (tags.length > 0) {
|
||||
tags.forEach((tag) => {
|
||||
@@ -58,6 +59,16 @@ export default {
|
||||
}
|
||||
}
|
||||
|
||||
if (unassigned) {
|
||||
if (card.assignedUsers.length > 0) {
|
||||
allUnassigned = false
|
||||
}
|
||||
|
||||
if (!allUnassigned) {
|
||||
return false
|
||||
}
|
||||
}
|
||||
|
||||
if (due !== '') {
|
||||
const datediffHour = ((new Date(card.duedate) - new Date()) / 3600 / 1000)
|
||||
switch (due) {
|
||||
|
||||
Reference in New Issue
Block a user