christillman / encounterpro_os

EncounterPro-OS Electronic Health Record Software
GNU Affero General Public License v3.0
0 stars 0 forks source link

Bug: In RTF scripts, "Prior Medications" treatment type not showing but "Current Medications" treatment type is showing #72

Closed MCIR closed 3 weeks ago

MCIR commented 2 months ago

Contact Details

No response

What happened?

Prior meds and current medications are important sections in a patient summary note, hence the reason why they were made into 2 categories, to make it possible to display them as separate sections in the patient summary RTF script.

After these new changes, the RTF script configured with these 2 treatment types ('Prior Medications' and 'Current Medications') does not show a patient's prior medications. It only shows the patient's current (prescribed) medications. Related to issue #65

How did it happen?

When 'Prior Medications" treatment type is added to an RTF script, medications that quality as a patient's prior medications are not showing in the script.

Expectations

Prior medications to be visible on the RTF script, in the same way current medications are visible on the RTF script.

Urgency and Importance

P3-Medium

Version

7.2.2.0

Relevant log output

No response

Code of Conduct

christillman commented 2 months ago

Hi Ciru,

There are two sections at the bottom of the script that print treatments. First comes Encounter Treatments which uses Standard Quick View Prescriptio Display5 . The Treatment_Type is set to MEDICATION.

image

The second one, Patient Treatments, also has Treatment_Type = MEDICATION, and calls Current Meds Dated w/out Notes.

image

That second one includes an "if" to check the treatment type, which I think is not necessary. But its effect is to skip the display of the treatment if the treatment_type is not 'Medication'

You must have copied one of these to create your new Prior Meds display script. Can you send how it looks? And in particular check that "if", if it is the Patient Treatment one, to confirm that it is checking for treatment_type = "PRIORMEDICATION" not "MEDICATION".

On Sat, Jul 20, 2024 at 1:14 AM Madeline Wanjiru @.***> wrote:

Contact Details

No response What happened?

Prior meds and current medications are important sections in a patient summary note, hence the reason why they were made into 2 categories, to make it possible to display them as separate sections in the patient summary RTF script.

After these new changes, the RTF script configured with these 2 treatment types ('Prior Medications' and 'Current Medications') does not show a patient's prior medications. It only shows the patient's current (prescribed) medications. How did it happen?

When 'Prior Medications" treatment type is added to an RTF script, medications that quality as a patient's prior medications are not showing in the script. Expectations

Prior medications to be visible on the RTF script, in the same way current medications are visible on the RTF script. Urgency and Importance

P3-Medium Version

7.2.2.0 Relevant log output

No response Code of Conduct

  • I agree to follow this project's Code of Conduct

— Reply to this email directly, view it on GitHub https://github.com/christillman/encounterpro_os/issues/72, or unsubscribe https://github.com/notifications/unsubscribe-auth/AGEGTU7CXS6PLKOM6EG24YLZNEGKDAVCNFSM6AAAAABLESNU6OVHI2DSMVQWIX3LMV43ASLTON2WKOZSGQYTQOBXGEZDAMQ . You are receiving this because you were assigned.Message ID: @.***>

-- Chris Tillman Developer

christillman commented 2 months ago

Hi Chris,

After reviewing your screenshot and the script you pointed out that could be the problem, I decided to explore the issue again, despite previous unsuccessful attempts.

I didn’t have a ‘Treatment Type’ known as ‘MEDICATIONS’ as seen in your screenshot below so, I kept my ‘Treatment Type’ as ‘Prior Medications’.

unnamed

I then decided to set the fields below ‘Treatment Type’ (‘Show Previous Treatments’, ‘Include Created In Plan’, ‘Treatment Status’ and ‘Encounter Owner’) to ‘NULL’ as seen below.

unnamed

After doing this, prior medications are now showing on the scripts but not exactly as they were entered in the ‘Prior Meds’ page. unnamed

There is a contrast between what they look like in the ‘Prior Meds’ page versus how they print on the RTF script. unnamed

The script that displays the medications is seen below unnamed

Wondering why it will not show formulations in instances where a formulation was entered.

christillman commented 2 months ago

why it will not show formulations in instances where a formulation was entered.

The answer to that is easy. We added formulations ourselves, and this code to print within RTFs was never touched in that process (not identified as a place that needed to display formulations). Do you want to have it print the same way in the RTF as it does in the chart page?

MCIR commented 3 weeks ago

Can now clearly see 'Prior Medications' and 'Current Medications' as distinct treatment types on RTF scripts.

christillman commented 3 weeks ago

Update was applied in 7.2.4.