diff --git a/client/src/components/job-search-select/job-search-select.component.jsx b/client/src/components/job-search-select/job-search-select.component.jsx index dcf32f722..614e0a060 100644 --- a/client/src/components/job-search-select/job-search-select.component.jsx +++ b/client/src/components/job-search-select/job-search-select.component.jsx @@ -19,6 +19,7 @@ const JobSearchSelect = ( disabled, convertedOnly = false, notExported = true, + clm_no = false, }, ref ) => { @@ -55,7 +56,7 @@ const JobSearchSelect = ( useEffect(() => { if (value === option && value) { - callIdSearch({ variables: { id: value } }); + callIdSearch({ variables: { id: value } }); // Sometimes results in a no-op. Not sure how to fix. } }, [value, option, callIdSearch]); @@ -66,10 +67,13 @@ const JobSearchSelect = ( } }; - const theOptions = [ - ...(idData && idData.jobs_by_pk ? [idData.jobs_by_pk] : []), - ...(data && data.search_jobs ? data.search_jobs : []), - ]; + const theOptions = _.uniqBy( + [ + ...(idData && idData.jobs_by_pk ? [idData.jobs_by_pk] : []), + ...(data && data.search_jobs ? data.search_jobs : []), + ], + "id" + ); return (
@@ -93,9 +97,9 @@ const JobSearchSelect = ( {theOptions ? theOptions.map((o) => (