Skip to content

Commit

Permalink
Rename prescribed_medication to treatment_plan (#6029)
Browse files Browse the repository at this point in the history
  • Loading branch information
Ashesh3 authored Aug 30, 2023
1 parent 4956ed8 commit cfd43d8
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 14 deletions.
4 changes: 2 additions & 2 deletions src/Components/Facility/ConsultationDetails.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -856,15 +856,15 @@ export const ConsultationDetails = (props: any) => {
</div>
</div>
)}
{consultationData.prescribed_medication && (
{consultationData.treatment_plan && (
<div className="overflow-hidden rounded-lg bg-white shadow">
<div className="px-4 py-5 sm:p-6">
<h3 className="text-lg font-semibold leading-relaxed text-gray-900">
Treatment Summary
</h3>
<div className="mt-2">
<ReadMore
text={consultationData.prescribed_medication}
text={consultationData.treatment_plan}
minChars={250}
/>
</div>
Expand Down
10 changes: 5 additions & 5 deletions src/Components/Facility/ConsultationForm.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ type FormDetails = {
kasp_enabled_date: null;
examination_details: string;
history_of_present_illness: string;
prescribed_medication: string;
treatment_plan: string;
consultation_notes: string;
patient_no: string;
procedure: ProcedureType[];
Expand Down Expand Up @@ -129,7 +129,7 @@ const initForm: FormDetails = {
kasp_enabled_date: null,
examination_details: "",
history_of_present_illness: "",
prescribed_medication: "",
treatment_plan: "",
consultation_notes: "",
patient_no: "",
procedure: [],
Expand Down Expand Up @@ -607,7 +607,7 @@ export const ConsultationForm = (props: any) => {
kasp_enabled_date: JSON.parse(state.form.is_kasp) ? new Date() : null,
examination_details: state.form.examination_details,
history_of_present_illness: state.form.history_of_present_illness,
prescribed_medication: state.form.prescribed_medication,
treatment_plan: state.form.treatment_plan,
discharge_date: state.form.discharge_date,
patient_no: state.form.patient_no,
icd11_diagnoses: state.form.icd11_diagnoses_object.map(
Expand Down Expand Up @@ -1182,10 +1182,10 @@ export const ConsultationForm = (props: any) => {
</div>
<div
className="col-span-6"
ref={fieldRef["prescribed_medication"]}
ref={fieldRef["treatment_plan"]}
>
<TextAreaFormField
{...field("prescribed_medication")}
{...field("treatment_plan")}
label="Treatment Plan / Treatment Summary"
placeholder="Optional information"
/>
Expand Down
6 changes: 2 additions & 4 deletions src/Components/Facility/TreatmentSummary.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -354,10 +354,8 @@ const TreatmentSummary = (props: any) => {

<div className="border-b-2 border-gray-800 px-5 py-2">
<b>Treatment :</b>
{consultationData.prescribed_medication ? (
<p className="ml-4">
{consultationData.prescribed_medication}
</p>
{consultationData.treatment_plan ? (
<p className="ml-4">{consultationData.treatment_plan}</p>
) : (
<p className="ml-4">---</p>
)}
Expand Down
2 changes: 1 addition & 1 deletion src/Components/Facility/models.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ export interface ConsultationModel {
modified_date?: string;
other_symptoms?: string;
patient?: string;
prescribed_medication?: string;
treatment_plan?: string;
referred_to?: number | null;
referred_to_object?: FacilityModel;
referred_to_external?: string;
Expand Down
2 changes: 1 addition & 1 deletion src/Components/Patient/PatientRegister.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ const initForm: any = {
test_id: "",
srf_id: "",
test_type: testType[0],
prescribed_medication: false,
treatment_plan: false,
ongoing_medication: "",
designation_of_health_care_worker: "",
instituion_of_health_care_worker: "",
Expand Down
2 changes: 1 addition & 1 deletion src/Components/Shifting/ShiftDetails.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -497,7 +497,7 @@ export default function ShiftDetails(props: { id: string }) {
<span className="font-semibold leading-relaxed">
{t("treatment_summary")}:{" "}
</span>
{consultation.prescribed_medication || "-"}
{consultation.treatment_plan || "-"}
</div>
</div>
<div className="mt-6 flex justify-between">
Expand Down

0 comments on commit cfd43d8

Please sign in to comment.