fix: public cards show all labels when filtered
This commit is contained in:
@@ -143,10 +143,13 @@ export const getBySlug = async (
|
|||||||
description,
|
description,
|
||||||
listId,
|
listId,
|
||||||
index,
|
index,
|
||||||
labels:label${filters.labels.length > 0 ? "!inner" : ""} (
|
labels:label(
|
||||||
publicId,
|
publicId,
|
||||||
name,
|
name,
|
||||||
colourCode
|
colourCode
|
||||||
|
),
|
||||||
|
_filteredLabels:label${filters.labels.length > 0 ? "!inner" : ""} (
|
||||||
|
publicId
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
@@ -158,7 +161,7 @@ export const getBySlug = async (
|
|||||||
.is("lists.cards.deletedAt", null);
|
.is("lists.cards.deletedAt", null);
|
||||||
|
|
||||||
if (filters.labels.length > 0) {
|
if (filters.labels.length > 0) {
|
||||||
query = query.in("lists.cards.labels.publicId", filters.labels);
|
query = query.in("lists.cards._filteredLabels.publicId", filters.labels);
|
||||||
}
|
}
|
||||||
|
|
||||||
const { data } = await query
|
const { data } = await query
|
||||||
|
|||||||
Reference in New Issue
Block a user