Update Greasemonkey code for Allscripts

yehster wrote on Wednesday, July 24, 2013:

I believe the reason why search fails sometimes is if the greasemonkey triggered search happens while the tab containing allscripts is “in the background.” Allscripts needs to be “active”. This is why search seems to work consistently on “login” (you have to activate the window to enter your password.) Also search always worked when I put allscripts in a browser window of it’s on a separate monitor. But if it is in a separate tab if you click over fast enough when hitting the allscripts button in OpenEMR it works, but if you just leave it running and then click over, it fails.

To address this I’ve done two things. As MD Support suggested I added a button labeled “OpenEMR” on the search screen which populates the search fields then clicks Allscripts’ search button. So after an initial login to Allscripts if one wants to search for a new patient based on the active OpenEMR patient, click the tab for Allscripts, then hit the OpenEMR button.

I’ve also changed the Allscripts button in OpenEMR. It now by default activates Allscripts in one of OpenEMR’s frames. (RBot by default RTop, if RBot is hidden.) This way the allscripts window is active.

I doesn’t look like Sourceforge lets you create an attachment for the initial post in a topic, so the next message in this thread will have the updated script attached.

yehster wrote on Wednesday, July 24, 2013:

Here is the updated script. Let me know of issues.

yehster wrote on Wednesday, July 24, 2013:

There is a checkbox next to the allscripts button now too. If you want it to work the “old way” (opens allscripts in a separate window) check it.

hitechelp wrote on Thursday, July 25, 2013:

Still not populating the search box for us either way, (new or old using check box)
workstation is Win8 sp1, FireFox 22. Server is Ubuntu 11.10, OpenEMR 4.1.1 (12)

weesnerkim wrote on Friday, July 26, 2013:

Not populating search box for me also. It only runs in RBot window on my website server, does not work on client only machines. By the way I also used your prescription_import table for my HL7-v3 CDA importer. The CDA contains more information than Allscripts excel file so I left the fields in the table that you deleted and just added presc_count and pi_error. I use all the old fields like they are named except for pharmacy_note and I use it for the RXNORM drug code. I am using both importers together with no trouble, just Allscripts website weirdness, I am also trying to figure out the GM search issue.
Kim

yehster wrote on Saturday, July 27, 2013:

What do you see when you click the additional “OpenEMR” button on the Allscripts site?
Can you check “about:config” and filter for the greasemonkey settings? Do you see entries for AllscriptsIntegration.patientXXXX?

hitechelp wrote on Saturday, July 27, 2013:

Kevin,

This is what I see after setting the system focus on a patient who is entered in Allsripts and clicking the OpenEMR button in Allscripts.

I can not locate anything resembling “about:config”. Where do I look?

Regards,

David

hitechelp wrote on Saturday, July 27, 2013:

Kevin,

I can not locate anything resembling “about:config”. Where do I look?

yehster wrote on Saturday, July 27, 2013:

type about:config in the URL bar at the top of Firefox as if you were going to a different page.You’ll get a warning from firefox about knowing what you are doing.

Then in the “search” box type greasemonkey
it should filter and show you some relevant information.

yehster wrote on Saturday, July 27, 2013:

When you hit the OpenEMR button, do you ever see the patient’s names displayed?

hitechelp wrote on Saturday, July 27, 2013:

Not that I can tell, on click, the screen jumps up vertically a little then settles back but I see nothing change in the patients name box.

the about:config view is attached

redstapler wrote on Saturday, July 27, 2013:

Kevin- I am very interested in your initiative however I do not have a complete understand of what you are attempting to achieve. I do not see very much background or detail in the post. Looks like you are doing some pretty cool integration.

yehster wrote on Monday, July 29, 2013:

When functioning correctly the patientFNAME,patientLNAME,patientDOBXXXX variables on the about:config screen for greasemonkey are supposed to reflect the current OpenEMR patient’s information.
One reason this might not be the case is that the prior versions of the script only understand the YYYY-MM-DD date format. So if you have changed this under globals>locale to MM/DD/YYYY or DD/MM/YYYY that would explain part of the problem.

This updated version will work with MM/DD/YYYY format now.

cverk wrote on Monday, July 29, 2013:

So far, that one seems to work great. It is pretty cool that you can have allscripts open up within the lower openemr window instead of in another browser window. It makes it easier to cross check your medication lists and enter prescription information into the patients chart.

fsgl wrote on Wednesday, July 31, 2013:

The new script partially works to populate established accounts in the Allscripts website for the free version (not Deluxe) in another tab. One cannot expect all the benefits without paying for it. Another freebie, another reason to be happy.

yehster wrote on Wednesday, July 31, 2013:

David,
The script being discussed is an updated version of
http://www.open-emr.org/wiki/index.php/OpenEMR_ePrescribe#Allscripts

redstapler wrote on Wednesday, July 31, 2013:

Thanks Kevin very cool nice option

David Nelsen , Healthcare Technical Analyst

m. 651-472-5678
e. david.nelsen@slingshot-hci.com
This e-mail, including attachments, may include confidential and/or
proprietary
information, and may be used only by the person or entity to which it is
addressed. If the reader of this e-mail is not the intended recipient or
his or her authorized agent, the reader is hereby notified that any
dissemination, distribution or copying of this e-mail is prohibited. If you
have received this e-mail in error, please notify the sender by replying to
this message and delete this e-mail immediately.

On Wed, Jul 31, 2013 at 2:45 PM, Kevin Yeh yehster@users.sf.net wrote:

David,
The script being discussed is an updated version of
OpenEMR ePrescribe - OpenEMR Project Wiki

Update Greasemonkey code for Allscriptshttps://sourceforge.net/p/openemr/discussion/202504/thread/4bf9f156/?limit=25#001c/ff88/b520

Sent from sourceforge.net because you indicated interest in
OpenEMR / Discussion / OpenEMR Users

To unsubscribe from further messages, please visit
SourceForge.net: Log In to SourceForge.net

marcin201 wrote on Sunday, August 18, 2013:

The script uses ‘id’ for MRN when adding patients using the ‘Load from OpenEMR’ button. The ‘id’ is assigned and auto incremented by OpenEMR. I have uploaded my existing patient demographics to OpenEMR db and stored the current MRN in ‘External ID’ (pubpid column in patient_data table). To have the script use the External ID for MRN change line 308 of the script from

patID=$("#gmOEMRInfo").find("input[name='db_id']").val();

to

patID=$("#gmOEMRInfo").find("input[name='form_pubpid']").val();

Marcin

van2010 wrote on Tuesday, August 12, 2014:

I have trouble loading up patient’s information from OpenEMR to Allscript in the last few days since Firefox update to the new version 31.0 (When I click on “Load from OpenEMR”, nothing happens).

Does anyone have this problem and do you have a fix for this yet?

I am using Windows 7 Pro

Thanks.

fsgl wrote on Tuesday, August 12, 2014:

I have Allscripts Free & would not notice this problem.

Script update or using Chrome was suggested here.