-
Notifications
You must be signed in to change notification settings - Fork 22
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: show related stages Widget on registration page
- Loading branch information
1 parent
bc2b962
commit ba81d9c
Showing
33 changed files
with
324 additions
and
144 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 3 additions & 0 deletions
3
...s/Enrollment/EnrollmentWithFirstStageDataEntry/EnrollmentWithFirstStageDataEntry.types.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,12 @@ | ||
// @flow | ||
import type { ProgramStage, RenderFoundation } from '../../../../metaData'; | ||
import type { RelatedStageRefPayload } from '../../../WidgetRelatedStages'; | ||
|
||
export type Props = { | ||
firstStageMetaData: { | ||
stage: ProgramStage, | ||
}, | ||
formFoundation: RenderFoundation, | ||
programId: string, | ||
relatedStageRef?: { current: ?RelatedStageRefPayload }, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
40 changes: 40 additions & 0 deletions
40
...taEntries/converters/getConvertedRelatedStageEvent/getConvertedRelatedStageEvent.types.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
// @flow | ||
import type { RelatedStageDataValueStates, RelatedStageRelationshipType } from '../../../WidgetRelatedStages'; | ||
import { RelatedStageModes } from '../../../WidgetRelatedStages'; | ||
|
||
type CommonEventDetails = { | ||
event: string, | ||
program: string, | ||
programStage: string, | ||
orgUnit: string, | ||
trackedEntity?: ?string, | ||
enrollment?: string, | ||
scheduledAt: string, | ||
dataValues: Array<{ dataElement: string, value: any }>, | ||
status?: string, | ||
} | ||
|
||
export type RequestEvent = { | ||
...CommonEventDetails, | ||
occurredAt: string, | ||
notes?: Array<{ value: string }>, | ||
completedAt?: string, | ||
} | ||
|
||
export type LinkedRequestEvent = { | ||
...CommonEventDetails, | ||
occurredAt?: string, | ||
completedAt?: string, | ||
} | ||
|
||
export type ConvertedRelatedStageEventProps = {| | ||
linkMode: $Keys<typeof RelatedStageModes>, | ||
relatedStageDataValues: RelatedStageDataValueStates, | ||
programId: string, | ||
teiId?: ?string, | ||
currentProgramStageId: string, | ||
enrollmentId?: string, | ||
relatedStageType: RelatedStageRelationshipType, | ||
clientRequestEvent: RequestEvent, | ||
|} | ||
|
4 changes: 4 additions & 0 deletions
4
...les/capture-core/components/DataEntries/converters/getConvertedRelatedStageEvent/index.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
// @flow | ||
|
||
export { getConvertedRelatedStageEvent } from './getConvertedRelatedStageEvent'; | ||
export type { RequestEvent, LinkedRequestEvent } from './getConvertedRelatedStageEvent.types'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.