Commit 7d5ea627 authored by Florie Guibert's avatar Florie Guibert

Add Confidential filter to issue boards new filtered search

Fix URL
parent 983f7d1e
import { sortBy, cloneDeep } from 'lodash'; import { sortBy, cloneDeep } from 'lodash';
import { isGid } from '~/graphql_shared/utils'; import { isGid } from '~/graphql_shared/utils';
import { parseBoolean } from '~/lib/utils/common_utils';
import { ListType, MilestoneIDs, AssigneeFilterType, MilestoneFilterType } from './constants'; import { ListType, MilestoneIDs, AssigneeFilterType, MilestoneFilterType } from './constants';
export function getMilestone() { export function getMilestone() {
...@@ -223,7 +222,7 @@ export const FiltersInfo = { ...@@ -223,7 +222,7 @@ export const FiltersInfo = {
}, },
confidential: { confidential: {
negatedSupport: false, negatedSupport: false,
transform: (val) => parseBoolean(val), transform: (val) => val === 'yes',
}, },
search: { search: {
negatedSupport: false, negatedSupport: false,
......
...@@ -143,8 +143,8 @@ export default { ...@@ -143,8 +143,8 @@ export default {
token: GlFilteredSearchToken, token: GlFilteredSearchToken,
operators: OPERATOR_IS_ONLY, operators: OPERATOR_IS_ONLY,
options: [ options: [
{ icon: 'eye-slash', value: true, title: __('Yes') }, { icon: 'eye-slash', value: 'yes', title: __('Yes') },
{ icon: 'eye', value: false, title: __('No') }, { icon: 'eye', value: 'no', title: __('No') },
], ],
}, },
] ]
......
...@@ -456,8 +456,8 @@ export const mockTokens = (fetchLabels, fetchAuthors, fetchMilestones, fetchIter ...@@ -456,8 +456,8 @@ export const mockTokens = (fetchLabels, fetchAuthors, fetchMilestones, fetchIter
token: GlFilteredSearchToken, token: GlFilteredSearchToken,
operators: [{ value: '=', description: 'is' }], operators: [{ value: '=', description: 'is' }],
options: [ options: [
{ icon: 'eye-slash', value: true, title: 'Yes' }, { icon: 'eye-slash', value: 'yes', title: 'Yes' },
{ icon: 'eye', value: false, title: 'No' }, { icon: 'eye', value: 'no', title: 'No' },
], ],
}, },
{ {
......
...@@ -560,8 +560,8 @@ export const mockConfidentialToken = { ...@@ -560,8 +560,8 @@ export const mockConfidentialToken = {
token: GlFilteredSearchToken, token: GlFilteredSearchToken,
operators: [{ value: '=', description: 'is' }], operators: [{ value: '=', description: 'is' }],
options: [ options: [
{ icon: 'eye-slash', value: true, title: 'Yes' }, { icon: 'eye-slash', value: 'yes', title: 'Yes' },
{ icon: 'eye', value: false, title: 'No' }, { icon: 'eye', value: 'no', title: 'No' },
], ],
}; };
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment