Procedure

TfrmODMedNVA.SetupDialog

Directives

Override

Module

fODMedNVA

Last Modified

7/15/2014 3:26:42 PM

Comments

AnInstr: string;

Visibility

Public

Overrides

TfrmODBase.SetupDialog

Owner

TfrmODMedNVA

Declaration

procedure SetupDialog(OrderAction: Integer; const ID: string); override;

Calls Hierarchy


TfrmODMedNVA.SetupDialog
 ├TfrmODBase.SetDisplayGroup
 ├DisplayGroupByName
 ├CheckExistingPI
 ├TResponses.IValueFor
 ├TfrmODMedNVA.SetOnMedSelect
 │ ├GetPKISite
 │ ├TCtrlInits.LoadOrderItem
 │ │ ├TCtrlInits.ClearOI
 │ │ └TCtrlInits.ExtractInits
 │ │   └TCtrlInit.Create
 │ ├OIForNVA
 │ ├TCtrlInits.SetControl
 │ │ ├ClearControl
 │ │ └TCtrlInits.FindInitByName
 │ ├TfrmODMedNVA.cboRouteChange
 │ │ └TfrmODMedNVA.ControlChange
 │ │   ├TResponses.Clear
 │ │   ├TResponses.Update
 │ │   │ ├TResponses.FindResponseByName
 │ │   │ └TResponses.IENForPrompt
 │ │   ├TfrmODMedNVA.FindCommonDrug
 │ │   │ ├TfrmODMedNVA.FindDoseFields
 │ │   │ ├SaveDrug
 │ │   │ └KillDrug
 │ │   ├TfrmODMedNVA.ConstructedDoseFields
 │ │   ├TfrmODMedNVA.ValueOf
 │ │   │ ├GetSchedule
 │ │   │ └GetScheduleEX
 │ │   ├TfrmODMedNVA.OutpatientSig
 │ │   │ ├TfrmODMedNVA.ValueOf...
 │ │   │ └TfrmODMedNVA.CheckDecimal
 │ │   └TResponses.GetOrderText
 │ │     ├TResponses.NextInstance
 │ │     ├TResponses.FindResponseByName
 │ │     ├TResponses.FormatResponse
 │ │     │ └TResponses.FindResponseByIEN
 │ │     └TResponses.AppendChildren
 │ │       ├TResponses.FindPromptByIEN
 │ │       ├TResponses.FindResponseByIEN
 │ │       └TResponses.FormatResponse...
 │ ├TCtrlInits.DefaultText
 │ │ └TCtrlInits.FindInitByName
 │ ├TfrmODMedNVA.ValueOf...
 │ └TCtrlInits.TextOf
 │   └TCtrlInits.FindInitByName
 ├TfrmODMedNVA.SetOnQuickOrder
 │ ├TResponses.InstanceCount
 │ ├TResponses.NextInstance
 │ ├TfrmODMedNVA.SetDosage
 │ ├TResponses.IValueFor
 │ ├TResponses.SetControl
 │ │ ├TResponses.FindResponseByName
 │ │ └AssignBPText
 │ │   ├DisplayGroupToLinkType
 │ │   │ └DisplayGroupByName
 │ │   ├TResponses.EValueFor
 │ │   ├GetServiceIEN
 │ │   ├TResponses.IValueFor
 │ │   ├GetProcedureIEN
 │ │   ├ExpandOrderObjects
 │ │   │ ├TdmodShared.BoilerplateOK
 │ │   │ │ ├ErrCount
 │ │   │ │ ├AddErr
 │ │   │ │ └TdmodShared.LoadTIUObjects
 │ │   │ │   └GetObjectList
 │ │   │ └GetTemplateText
 │ │   │   └TEncounter.GetVisitStr
 │ │   │     └TEncounter.GetVisitCategory
 │ │   ├SetTemplateDialogCanceled
 │ │   ├CheckBoilerplate4Fields
 │ │   ├ExecuteTemplateOrBoilerPlate
 │ │   └WasTemplateDialogCanceled
 │ ├TfrmODMedNVA.SetSchedule
 │ ├TfrmODMedNVA.ValueOf...
 │ ├QuantityMessage
 │ ├TfrmODMedNVA.SetStartDate
 │ ├TResponses.EValueFor
 │ ├TfrmODMedNVA.SetStatements
 │ │ └TfrmODMedNVA.SearchStatements
 │ ├QOHasRouteDefined
 │ ├GetPickupForLocation
 │ ├TResponses.FindResponseByName
 │ ├NameOfDGroup
 │ │ └LoadDGroupMap
 │ ├TfrmODMedNVA.ValueOfResponse
 │ │ └TResponses.IValueFor
 │ └TfrmODMedNVA.UpdateStartExpires
 │   ├LoadAdminInfo
 │   └FMToday
 │     └FMNow
 ├TfrmODMedNVA.ShowMedFields
 │ └TfrmODMedNVA.ShowControlsSimple
 ├OrderIsReleased
 ├TfrmODMedNVA.UpdateRelated
 │ └TfrmODMedNVA.timCheckChangesTimer
 │   ├TfrmODMedNVA.ControlChange...
 │   ├TResponses.NextInstance
 │   ├TfrmODMedNVA.ValueOfResponse...
 │   ├TfrmODMedNVA.ValueOf...
 │   └TfrmODMedNVA.UpdateStartExpires...
 └TfrmODMedNVA.ControlChange...

Calls

Name Declaration Comments
CheckExistingPI procedure CheckExistingPI(AOrderId: string; var APtI: string); -
TfrmODMedNVA.ControlChange procedure ControlChange(Sender: TObject); -
DisplayGroupByName function DisplayGroupByName(const AName: string): Integer; -
TResponses.IValueFor function IValueFor(const APromptID: string; AnInstance: Integer): string; -
OrderIsReleased function OrderIsReleased(const ID: string): Boolean; -
TfrmODBase.SetDisplayGroup procedure SetDisplayGroup(Value: Integer); -
TfrmODMedNVA.SetOnMedSelect procedure SetOnMedSelect; -
TfrmODMedNVA.SetOnQuickOrder procedure SetOnQuickOrder; -
TfrmODMedNVA.ShowMedFields procedure ShowMedFields; -
TfrmODMedNVA.UpdateRelated procedure UpdateRelated(DelayUpdate: Boolean = TRUE); -


Source

423   procedure TfrmODMedNVA.SetupDialog(OrderAction: Integer; const ID: string);
424   var
425     //AnInstr: string;
426     OrderID: string;
427   begin
428     inherited;
429    // if FInptDlg and (not FOutptIV) then DisplayGroup := DisplayGroupByName('UD RX')
430     DisplayGroup := DisplayGroupByName('NV RX');   // CLA 6/3/03
431     if XfInToOutNow then DisplayGroup := DisplayGroupByName('O RX');
432     if CharAt(ID,1)='X' then
433     begin
434       OrderID := Copy(Piece(ID, ';', 1), 2, Length(ID));
435       CheckExistingPI(OrderID, FPtInstruct);
436     end;
437     if OrderAction = ORDER_QUICK then
438       FIsQuickOrder := True
439     else
440       FIsQuickOrder := False;
441   //  if OrderAction in [ORDER_COPY, ORDER_EDIT] then Responses.Remove('START', 1);
442     if OrderAction in [ORDER_COPY, ORDER_EDIT, ORDER_QUICK] then
443     begin
444       Changing := True;
445       txtMed.Tag  := StrToIntDef(Responses.IValueFor('ORDERABLE', 1), 0);
446       SetOnMedSelect;
447       SetOnQuickOrder;                                  // set up for this medication
448       ShowMedFields;
449       if (OrderAction = ORDER_EDIT) and OrderIsReleased(Responses.EditOrder)
450         then btnSelect.Enabled := False;
451       UpdateRelated(FALSE);
452       Changing := False;
453     end;
454     { prevent the SIG from being part of the comments on pre-CPRS prescriptions }
455     {if (OrderAction in [ORDER_COPY, ORDER_EDIT]) and (cboDosage.Text = '') then  //commented out by cla 2/27/04 - CQ 2591
456     begin
457       OrderID := Copy(Piece(ID, ';', 1), 2, Length(ID));
458       AnInstr := TextForOrder(OrderID);
459       pnlMessage.TabOrder := 0;
460       OrderMessage(AnInstr);
461       if OrderAction = ORDER_COPY
462         then AnInstr := 'Copy: ' + AnInstr
463         else AnInstr := 'Change: ' + AnInstr;
464       Caption := AnInstr;
465       memComment.Clear;  // sometimes the sig is in the comment
466       lbStatements.Clear;
467     end;}
468     ControlChange(Self);
469   end;