Skip to content

Commit

Permalink
fix: remove orgUnit param if ouMode = ACCESSIBLE, CAPTURE or ALL
Browse files Browse the repository at this point in the history
  • Loading branch information
superskip committed Aug 23, 2023
1 parent 8bed7fb commit 9b0cd40
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,6 @@ export const loadSearchGroupDuplicatesForReviewEpic = (
payload: {
page,
pageSize,
orgUnitId,
selectedScopeId,
scopeType,
dataEntryId,
Expand All @@ -73,7 +72,6 @@ export const loadSearchGroupDuplicatesForReviewEpic = (

const contextParam = scopeType === scopeTypes.TRACKER_PROGRAM ? { program: selectedScopeId } : { trackedEntityType: selectedScopeId };
const queryArgs = {
ou: orgUnitId,
ouMode: 'ACCESSIBLE',
pageSize,
page,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ import { getSearchFormId } from '../getSearchFormId';
import type { QuerySingleResource } from '../../../utils/api/api.types';

const getOuQueryArgs = (orgUnit: ?Object, orgUnitScope: string) =>
(orgUnitScope !== 'ACCESSIBLE' ?
(orgUnitScope !== 'ACCESSIBLE' || 'CAPTURE' || 'ALL' ?
{ ou: orgUnit && orgUnit.id, ouMode: orgUnitScope } :
{ ouMode: orgUnitScope });

Expand Down

0 comments on commit 9b0cd40

Please sign in to comment.