List of Reminders due

Hi Just wondering if someone does this or can point me in the right direction.

We use a Patient Form pre printed for each appointment. I have attached the file - feel free to use it if you like it!

Current the nurses complete the section on the Reminders manually. I have been looking for a merge field that looks for reminders listed on a patients file such that they can automatically print out on the form. But could not find one.

 

Also I read somewhere that the vacciantion certificates can now list when the next vaccination is due but again cannot see that merge field.

Thanks for you help, Anna

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

Re: List of Reminders due

Anna - getting reminders into a patient form: 

I think that the best way to do this is via the report macro facility - ie use a macro that invokes a report to dump the patient's reminders.  We use this technique to include the patient's vaccination history on their vaccination certificate. The system already contains the necessary functions - see http://www.openvpms.org/documentation/csh/1.8/reference/jxpath#reminder

Note that these functions return the reminders for ALL the customer's patients. However, it should be possible to code the jrxml template so as to only include the current patient - by the simple expedient of not printing the reminder if the patient's name does not match the current one.

A variant of the above should also be able to handle your 'vaccination due' problem - by tweaking things so that only reminders whose name contains 'vaccination' are listed.

If nobody comes forward offering an existing solution, I will see if I can get time to build one for you.

 

Regards, Tim G

Re: List of Reminders due

Thanks Tim ... I will have a look at the link to see what I can do too.

Anna

Re: List of Reminders due

Anna - I got bored updating reports so I had a quick play. The document templates are attached. Use Administration|Templates|New to load these - the first as a report, the second as a subreport. Remember to leave the file name of the subreport content as 'RPTM ReminderItems.jrxml' unless you also adjust the content name of the subreport in RPTM Reminders. [The RPTM is just my naming convention - stands for RePorT Macro.]

Then use Administration|Lookups|New to create the Report Macro as follows:

The code and name can be whatever you want - again the '@_RM...' follows my convention for naming report macros.

As per http://www.openvpms.org/documentation/csh/1.8/admin/lookup/macroReport the Expression is critical.  The above (with the '$patient') is set up for using this as macro. Change it to '.' for use in a Open Office document.

I always use the $ form when developing these report macros so that I can test them quickly by invoking them in an email create window.

Here is the output as the document templates are currently.  Nothing is output by the report - all comes from the subreport and this shows the due date, reminder type and patient name, ie

What reminders are selected is defined by the subreport datasource expression in the report - currently it is:

$P{dataSource}.getExpressionDataSource("reminder:getReminders(., 3, 'MONTHS')")

ie only reminders with due dates in the next 3 months are shown.

It you want you can adjust the data displayed - the field names are those in act.patientReminder

Two final hints:

1) when things go wrong - ie when you are testing and you enter @_RMreminders and nothing happens - go look at the openvpms-full.log in the <TOMCAT-HOME>\logs folder - ie C:\Program Files\Apache Software Foundation\Tomcat 7.0\logs in my system.

2) the report macro simply returns text strings. The above example appears to have its columns lined up - but if I increase the lenght of the name of the reminder type we get

If I dump the text in fixed pitch font (courier) we get

So when you adjust your Customer and Patient Details.odt you will need to use a fixed pitch font for the reminder information to keep the columns organised. You can use a standard proportional font (say Times Roman) IF you only output the due date and the reminder type - this will work because in a proportional font all digits have the same width - so the date column always has the same width.

Have fun, Regards Tim G

AttachmentSize
RPTM Reminders.jrxml 2.54 KB
RPTM ReminderItems.jrxml 3.69 KB

Re: List of Reminders due

Hi Tim,

Thanks for your help.... must be doing something right as I got the list when I used the macro in a patient's history but when I added the macro to the Open Office document would not expand... I will try again and have a look into the log you suggested.

You mentioned that it will list the reminders for the next 3 months how do I get it to list all the reminders listed?

Thanks for your help! Anna

Re: List of Reminders due

Anna:

a) to get all reminders change the period from 3 MONTHS to say 20 YEARS in the subreport dataSource expression - as it says above.  See also http://www.openvpms.org/documentation/csh/1.8/reference/jxpath#reminder

b) not working in OO document - did you change $patient to . as per the above statement

 

Regards, Tim G

Re: List of Reminders due

Thanks Tim for your help - but even with the links to look at how macro reports work it is way above my understanding:(

Cath Colton has been my go to person understanding iReport - will she know how walk me through doing the report? I would like to know so then I can do others? Thanks again Anna

Re: List of Reminders due

OK - I have a solution which generates:

As well as the attached stuff you need to create the following Report Macro (via Administration|Lookups) - the red underlined bits need to be as I have them.

You need to install the document templates as follows:

File Template Name Type
AP Customer and Patient details.odt as you want Patient Form (or Letter)
RPTM Reminders.jrxml RPTM Reminders Report
RPTM ReminderItems.jrxml RPTM ReminderItems Subreport

Regards, Tim G

AttachmentSize
RPTM ReminderItems.jrxml 3.32 KB
RPTM Reminders.jrxml 3.33 KB
AP Customer and Patient Details.odt 19.44 KB

Re: List of Reminders due

Thank you so much Tim & Tim! It works a treat - will be forever grateful as will my nurses that previously did it manually. Anna

Syndicate content