Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

O3-4280: implement Save a note in Visit Patient scenario #66

Merged
merged 9 commits into from
Feb 25, 2025
Prev Previous commit
change custom representation in getCurrentVisit and send real time
  • Loading branch information
Bawanthathilan committed Feb 25, 2025
commit 1d5fef1591fdca35c59e683ac387adae0fecf2aa
Original file line number Diff line number Diff line change
@@ -291,14 +291,14 @@ public HttpRequestActionBuilder saveOrder(String patientUuid, String visitUuid,

public HttpRequestActionBuilder saveVisitNote(String patientUuid, String currentUser, String value) {
ZonedDateTime now = ZonedDateTime.now();
String formattedStopDateTime = now.format(DateTimeFormatter.ofPattern("yyyy-MM-dd'T'HH:mm:ss.SSSZ"));
String encounterDatetime = now.format(DateTimeFormatter.ofPattern("yyyy-MM-dd'T'HH:mm:ss.SSSZ"));

Map<String, Object> visitNote = new HashMap<>();
visitNote.put("form", VISIT_NOTE_FORM_UUID);
visitNote.put("patient", patientUuid);
visitNote.put("location", OUTPATIENT_CLINIC_LOCATION_UUID);
visitNote.put("encounterType", VISIT_NOTE_ENCOUNTER_TYPE_UUID);
visitNote.put("encounterDatetime", formattedStopDateTime);
visitNote.put("encounterDatetime", encounterDatetime);

Map<String, Object> encounterProvider = new HashMap<>();
encounterProvider.put("encounterRole", CLINICIAN_ENCOUNTER_ROLE);