diff --git a/frontend/src/components/project/partials/FilterInput.vue b/frontend/src/components/project/partials/FilterInput.vue index e4221a1fc..cfb8bd92f 100644 --- a/frontend/src/components/project/partials/FilterInput.vue +++ b/frontend/src/components/project/partials/FilterInput.vue @@ -211,9 +211,9 @@ function handleFieldInput() { function autocompleteSelect(value) { filterQuery.value = filterQuery.value.substring(0, autocompleteMatchPosition.value + 1) + - (autocompleteResultType.value === 'labels' - ? value.title - : value.username) + + (autocompleteResultType.value === 'assignees' + ? value.username + : value.title) + filterQuery.value.substring(autocompleteMatchPosition.value + autocompleteMatchText.value.length + 1) autocompleteResults.value = [] diff --git a/frontend/src/components/project/partials/filters.vue b/frontend/src/components/project/partials/filters.vue index 7b5b87418..85da6412c 100644 --- a/frontend/src/components/project/partials/filters.vue +++ b/frontend/src/components/project/partials/filters.vue @@ -88,7 +88,7 @@ watchDebounced( val.filter = transformFilterStringFromApi( val?.filter || '', labelId => labelStore.getLabelById(labelId)?.title, - projectId => projectStore.projects.value[projectId]?.title || null, + projectId => projectStore.projects[projectId]?.title || null, ) params.value = val }, diff --git a/frontend/src/helpers/filters.ts b/frontend/src/helpers/filters.ts index d8e4b2bd5..87d2b7263 100644 --- a/frontend/src/helpers/filters.ts +++ b/frontend/src/helpers/filters.ts @@ -33,6 +33,7 @@ export const AVAILABLE_FILTER_FIELDS = [ ...DATE_FIELDS, ...ASSIGNEE_FIELDS, ...LABEL_FIELDS, + ...PROJECT_FIELDS, ] export const FILTER_OPERATORS = [