Ask at Order - Lab

juggernautsei wrote on Wednesday, April 27, 2016:

Still trying to get through this setup and configuration process and the AOE as they call it (Ask at Order Entry).
I have imported the questions into the table. Now how do I trigger the questions?

sunsetsystems wrote on Wednesday, April 27, 2016:

When you are entering an order, the logic checks for questions where the lab ID and procedure code match what you are entering. If they do, the question should appear.

Rod
http://www.sunsetsystems.com/

juggernautsei wrote on Thursday, April 28, 2016:

Rod,
Thanks for the info. But the issue is populating the table because lab_id is set as a primary key and the table won’t allow for two entries to have the same key. So to get the import to work, I removed all primary keys from the table.

juggernautsei wrote on Thursday, April 28, 2016:

sunsetsystems wrote on Thursday, April 28, 2016:

Primary key for the procedure_questions table is (should be) a combination of lab_id, procedure_code and question_code. It should not be necessary to remove that.

Rod
http://www.sunsetsystems.com/

juggernautsei wrote on Friday, April 29, 2016:

Then I am not understanding what is the lab_id. I thought the lab_id is the ID of the lab the question belongs. I tried having unique ID’s for the lab_id in the attached file. However since none of them matched the lab company procedure_providers. None of the questions would show. It wasn’t till I set all lab_id’s to 1 that the AOE’s apeared. But in order to do that. I had to remove all of the primary key attribute from the table to import the data.

I had to change the explode on from ; to | in the gen_hl7.php file.

sunsetsystems wrote on Friday, April 29, 2016:

As previously noted, the primary key is a composite hey. Yes lab_id does identify the lab and so by itself is not unique, even though it is the first component of the primary key.

See interface/orders/load_compendium.php for sample code that loads AOE questions. Search for “procedure_questions”.

Rod
http://www.sunsetsystems.com/

juggernautsei wrote on Monday, May 09, 2016:

Working through the load_compendium.php file and came upon the load aoe

      // What should be uploaded is the "AOE Questions" spreadsheet provided by
      // PathGroup, saved in "Text CSV" format from OpenOffice, using its
      // default settings.  Values for each row are:
      //   0: OBRCode (order code)
      //   1: Question Code
      //   2: Question
      //   3: "Tips"
      //   4: Required (0 = No, 1 = Yes)
      //   5: Maxchar (integer length)
      //   6: FieldType (FT = free text, DD = dropdown, ST = string)
      //

In the database there is a column for options. Should 7: be options?

And is the load file coded to import options?

I have tried the attached file three times and it will not load into the database table.

juggernautsei wrote on Friday, May 13, 2016:

Next Issue is saving multiple choice AOE question. A question with a text box saves well. However, a multiple choice question does not save at all.

Post Array is as follows

array (size=16)
  'form_provider_id' => string '9' (length=1)
  'form_lab_id' => string '1' (length=1)
  'form_date_ordered' => string '2016-04-26' (length=10)
  'form_date_collected' => string '2016-04-26 21:38' (length=16)
  'form_order_priority' => string 'normal' (length=6)
  'form_order_status' => string 'routed' (length=6)
  'form_clinical_hx' => string '' (length=0)
  'form_patient_instructions' => string '' (length=0)
  'form_proc_order_title' => 
    array (size=1)
      0 => string 'Procedure' (length=9)
  'form_proc_type_desc' => 
    array (size=1)
      0 => string 'Urinalysis Screen with Microsopic if indicated and urine cultur' (length=63)
  'form_proc_type' => 
    array (size=1)
      0 => string '203' (length=3)
  'form_proc_type_diag' => 
    array (size=1)
      0 => string 'ICD10:Z00.00' (length=12)
  0 => string 'URINE URINE' (length=11)
  '_' => string 'CLEAN CATCH MIDSTREAM URM' (length=25)
  'procedure_type_names' => string 'procedure' (length=9)
  'bn_save' => string 'Save' (length=4)

I am trying to follow the logic.
When var_dump this
$data = $_POST["$prefix$qcode"];

It is empty. Should there be a period between $prefix and $qcode?

sunsetsystems wrote on Friday, May 13, 2016:

I would first look at the procedure_questions table and make sure it contains what you expect.

Rod
http://www.sunsetsystems.com/

juggernautsei wrote on Monday, May 16, 2016:

I had the field type set to ‘M’ for multiple choice and changed it to DD which meant that I had to change the database table fldtype from char(1) to char(2).

Now it saves the question data. No further changes made.

I am looking for sample data for the AOE table. Is there anyone that can share some sample data?

I have them for LabCorp and Quest compendiums! Based on openemr v7.0.0 database.

@sjpadgett I have the AOE.TXT file downloaded from Quest compendium. I have imported the compendium. I am building a feature to update the compendium from the UI.
I need to match the data to columns. I have looked at their document that describes what each field is supposed to be. I am just trying to get it right on the first go round.

When you look at the log file, that is a dump of the data in the AOE.TXT file. I have mapped some of the columns. I know that 16 should go in the last column of the table. Array item 3 should match the order ID. I could find the order ID in the procedure_type from the AOE list. I was just asking before I make the commit to code the import process. But is only code.

aoe.log (2.7 KB)

After this, we go in to testing so that once certified this time it will be for the parent company Quest. The previous certification was only for one of their child companies that does not grant a listing for all of Quest holdings.

I thought as much because not only are AOE required but also specimens and container descriptions for Quest. The existing procedure orders form has all the requirements implemented for a Quest full certification. As long as Quest is NPI or name of lab, I don’t remember which.

I have Quest, LabCorp and Ammon compendiums with QOA already mapped for LabCorp and Quest you can import but you’d need to match provider with compendium lab ids etc.
I may still have the complete compendium import from spreadsheet for quest somewhere.

Anyway I’ll email export for v702 of types and questions.

Hi Jerry- @sjpadgett
Could you please share the LabCorp compendium for v702 with me too?
Best- HT