Function

TfrmOrders.GetOrderText

Module

fOrders

Last Modified

7/15/2014 3:26:42 PM

Visibility

Private

Owner

TfrmOrders

Declaration

function GetOrderText(AnOrder: TOrder; Index: integer; Column: integer): string;

Calls Hierarchy


TfrmOrders.GetOrderText
 ├LoadFlagReason
 ├TfrmOrders.GetStartStopText
 └NameOfStatus

Called-By Hierarchy


                                      TfrmOrders.GetOrderText
                                    TfrmOrders.GetPlainText┤ 
                                   TfrmOrders.NotifyOrder┤ │ 
                                   TfrmFrame.UMNewOrder┘ │ │ 
                               TfrmOrders.RedrawOrderList┤ │ 
                              TfrmOrders.NotifyOrder...┤ │ │ 
                      TfrmOrders.hdrOrdersSectionResize┤ │ │ 
                    TfrmOrders.mnuOptimizeFieldsClick┘ │ │ │ 
                             TfrmFrame.WMSysCommand┤   │ │ │ 
                             TfrmOrders.SetFontSize┤   │ │ │ 
                             TfrmFrame.ChangeFont┘ │   │ │ │ 
                     TfrmFrame.LoadSizesForUser┤   │   │ │ │ 
                TfrmFrame.LoadUserPreferences┘ │   │   │ │ │ 
                       TfrmFrame.UMInitiate┘   │   │   │ │ │ 
                     TfrmFrame.mnuFontSizeClick┘   │   │ │ │ 
                   TfrmOrders.hdrOrdersSectionClick┤   │ │ │ 
                            TfrmOrders.sptHorzMoved┘   │ │ │ 
                           TfrmOrders.mnuActChangeClick┤ │ │ 
                              TfrmOrders.SetFontSize...┘ │ │ 
                             TfrmOrders.SynchListToOrders┤ │ 
                              TfrmOrders.NotifyOrder...┤ │ │ 
                               TfrmOrders.mnuActDCClick┤ │ │ 
                          TfrmOrders.mnuActChgEvntClick┤ │ │ 
                             TfrmOrders.mnuActHoldClick┤ │ │ 
                           TfrmOrders.mnuActUnholdClick┤ │ │ 
                            TfrmOrders.mnuActRenewClick┤ │ │ 
                         TfrmOrders.mnuActCompleteClick┤ │ │ 
                           TfrmOrders.mnuActVerifyClick┤ │ │ 
                         TfrmOrders.mnuActChartRevClick┤ │ │ 
                                TfrmOrders.RequestPrint┘ │ │ 
                          TfrmFrame.mnuFilePrintClick┘   │ │ 
                                  TfrmOrders.AddToListBox┘ │ 
                            TfrmOrders.RefreshOrderList┘   │ 
                            TfrmOrders.NotifyOrder...┤     │ 
                              TfrmOrders.SetOrderView┤     │ 
                      TfrmOrders.mnuViewActiveClick┤ │     │ 
                     TfrmOrders.mnuViewCurrentClick┤ │     │ 
                    TfrmOrders.mnuViewExpiringClick┤ │     │ 
                     TfrmOrders.mnuViewExpiredClick┤ │     │ 
                    TfrmOrders.mnuViewUnsignedClick┤ │     │ 
                  TfrmOrders.ProcessNotifications┘ │ │     │ 
                         TfrmOrders.DisplayPage┘   │ │     │ 
                       TfrmOrders.ViewAlertedOrders┘ │     │ 
               TfrmOrders.ProcessNotifications...┘   │     │ 
                        TfrmOrders.mnuViewCustomClick┤     │ 
                      TfrmOrders.mnuViewDfltShowClick┤     │ 
                             TfrmOrders.DisplayPage┘ │     │ 
                            TfrmOrders.lstSheetsClick┤     │ 
                       TfraEvntDelayList.CheckMatch┤ │     │ 
                          TfrmOrdersTS.cmdOKClick┘ │ │     │ 
TfrmOrdersTS.fraEvntDelayListmlstEventsDblClick┤   │ │     │ 
                       TfrmOrdersTS.FormKeyDown┘   │ │     │ 
                 TfraEvntDelayList.mlstEventsChange┤ │     │ 
   TfrmOrdersTS.fraEvntDelayListcboEvntListChange┤ │ │     │ 
    TfrmOrdersTS.fraEvntDelayListmlstEventsChange┤ │ │     │ 
    TfrmMedCopy.fraEvntDelayListcboEvntListChange┤ │ │     │ 
     TfrmMedCopy.fraEvntDelayListmlstEventsChange┤ │ │     │ 
 TfrmCopyOrders.fraEvntDelayListcboEvntListChange┤ │ │     │ 
  TfrmCopyOrders.fraEvntDelayListmlstEventsChange┘ │ │     │ 
                 TfrmOrders.mnuViewDfltShowClick...┤ │     │ 
                                          ..(rec)..┤ │     │ 
                           TfrmOrders.lstWriteClick┤ │     │ 
                         TfrmOrders.mnuActCopyClick┤ │     │ 
                         TfrmOrders.mnuActSignClick┤ │     │ 
                          TfrmOrders.ResetOrderPage┤ │     │ 
                  TfrmOrders.btnDelayedOrderClick┘ │ │     │ 
              TfrmOrders.PlaceOrderForDefaultDialog┤ │     │ 
                 TfrmOrders.DisplayDefaultDlgList┤ │ │     │ 
                   TfrmOrders.ResetOrderPage...┘ │ │ │     │ 
                                DisplayEvntDialog┤ │ │     │ 
                            SetDelayEventForMed┘ │ │ │     │ 
                     TfrmMeds.mnuActCopyClick┘   │ │ │     │ 
                                DisplayEvntDialog┤ │ │     │ 
                                 SetViewForCopy┘ │ │ │     │ 
                   TfrmOrders.mnuActCopyClick┘   │ │ │     │ 
                                DisplayEvntDialog┘ │ │     │ 
                               ExecuteChangeEvt┘   │ │     │ 
                TfrmOrders.mnuActChgEvntClick┘     │ │     │ 
                           TfrmOrders.ClickLstSheet┤ │     │ 
            TfraEvntDelayList.mlstEventsChange...┤ │ │     │ 
                     TfrmOrders.ResetOrderPage...┤ │ │     │ 
                        ExecuteReleaseEventOrders┘ │ │     │ 
                      TfrmOrders.mnuActRelClick┘   │ │     │ 
                        TfrmOrders.InitOrderSheets2┤ │     │ 
                     TfrmFrame.mnuFileReviewClick┘ │ │     │ 
                          TfrmOrders.PtEvtCompleted┤ │     │ 
                       TfrmFrame.DetermineNextTab┤ │ │     │ 
                     TfrmFrame.mnuFileOpenClick┤ │ │ │     │ 
                         TfrmFrame.UMInitiate┤ │ │ │ │     │ 
                   TfrmFrame.mnuFileNextClick┤ │ │ │ │     │ 
              TfrmFrame.mnuFileOpenClick...┤ │ │ │ │ │     │ 
          TfrmFrame.mnuFileNotifRemoveClick┤ │ │ │ │ │     │ 
                  TfrmFrame.NextButtonClick┘ │ │ │ │ │     │ 
                TfrmFrame.SetUpNextButton┘   │ │ │ │ │     │ 
          TfrmFrame.mnuFileOpenClick...┤     │ │ │ │ │     │ 
                   TfrmFrame.FormResize┘     │ │ │ │ │     │ 
              TfrmFrame.ChangeFont...┘       │ │ │ │ │     │ 
                TfrmFrame.mnuFileRefreshClick┤ │ │ │ │     │ 
                TfrmOrders.CheckOrderStatus┤ │ │ │ │ │     │ 
            TfrmOrders.mnuActChgEvntClick┤ │ │ │ │ │ │     │ 
               TfrmOrders.mnuActHoldClick┤ │ │ │ │ │ │     │ 
             TfrmOrders.mnuActUnholdClick┤ │ │ │ │ │ │     │ 
              TfrmOrders.mnuActRenewClick┤ │ │ │ │ │ │     │ 
             TfrmOrders.mnuActChangeClick┤ │ │ │ │ │ │     │ 
               TfrmOrders.mnuActCopyClick┘ │ │ │ │ │ │     │ 
                     TfrmMeds.mnuActDCClick┤ │ │ │ │ │     │ 
                    TfrmMeds.CheckMedStatus┘ │ │ │ │ │     │ 
                 TfrmMeds.mnuActHoldClick┤   │ │ │ │ │     │ 
                TfrmMeds.mnuActRenewClick┤   │ │ │ │ │     │ 
               TfrmMeds.mnuActUnholdClick┤   │ │ │ │ │     │ 
               TfrmMeds.mnuActChangeClick┤   │ │ │ │ │     │ 
                 TfrmMeds.mnuActCopyClick┤   │ │ │ │ │     │ 
               TfrmMeds.mnuActRefillClick┘   │ │ │ │ │     │ 
                           TfrmFrame.ViewInfo┘ │ │ │ │     │ 
                        TfrmDCSumm.ViewInfo┤   │ │ │ │     │ 
                      TfrmConsults.ViewInfo┤   │ │ │ │     │ 
              TfrmFrame.pnlRemindersMouseUp┤   │ │ │ │     │ 
               TfrmFrame.RemindersChanged┘ │   │ │ │ │     │ 
                   TfrmFrame.FormCreate┘   │   │ │ │ │     │ 
                     TfrmFrame.pnlCIRNClick┤   │ │ │ │     │ 
               TfrmFrame.pnlVistaWebClick┤ │   │ │ │ │     │ 
                    TfrmFrame.FormKeyDown┘ │   │ │ │ │     │ 
                  TfrmFrame.pnlPatientClick┤   │ │ │ │     │ 
                    TfrmFrame.pnlVisitClick┤   │ │ │ │     │ 
              TfrmFrame.pnlPrimaryCareClick┤   │ │ │ │     │ 
                TfrmFrame.pnlRemindersClick┤   │ │ │ │     │ 
                 TfrmFrame.pnlPostingsClick┤   │ │ │ │     │ 
                     TfrmFrame.pnlFlagClick┤   │ │ │ │     │ 
                       TfrmFrame.laMHVClick┤   │ │ │ │     │ 
                      TfrmFrame.laVAA2Click┤   │ │ │ │     │ 
                        TfrmOrders.ViewInfo┤   │ │ │ │     │ 
                          TfrmMeds.ViewInfo┤   │ │ │ │     │ 
                       TfrmSurgery.ViewInfo┤   │ │ │ │     │ 
                         TfrmNotes.ViewInfo┤   │ │ │ │     │ 
                      TfrmProblems.ViewInfo┘   │ │ │ │     │ 
                    TfrmFrame.UpdateCCOWContext┘ │ │ │     │ 
                TfrmFrame.mnuFileOpenClick...┤   │ │ │     │ 
              TfrmFrame.ctxContextorCommitted┤   │ │ │     │ 
               TfrmFrame.StartCCOWContextor┘ │   │ │ │     │ 
                     TfrmFrame.FormCreate┘   │   │ │ │     │ 
       TfrmFrame.mnuFileResumeContextGetClick┘   │ │ │     │ 
                     TfrmFrame.mnuFileReviewClick┤ │ │     │ 
                     TfrmOrders.lstSheetsClick...┤ │ │     │ 
                         TfrmOrders.lstWriteClick┤ │ │     │ 
                         TfrmOrders.mnuActDCClick┤ │ │     │ 
                    TfrmOrders.mnuActChgEvntClick┤ │ │     │ 
                       TfrmOrders.mnuActHoldClick┤ │ │     │ 
                       TfrmOrders.mnuActFlagClick┤ │ │     │ 
                    TfrmOrders.mnuActCommentClick┤ │ │     │ 
                     TfrmOrders.mnuActChangeClick┤ │ │     │ 
                       TfrmOrders.mnuActCopyClick┤ │ │     │ 
                       TfrmOrders.mnuActSignClick┤ │ │     │ 
                  TfrmOrders.btnDelayedOrderClick┤ │ │     │ 
                         TfrmMeds.mnuActCopyClick┤ │ │     │ 
                          TfrmODActive.btnOKClick┘ │ │     │ 
                            TfrmOrders.UMEventOccur┤ │     │ 
                           TfrmMeds.mnuActCopyClick┤ │     │ 
                            TfrmMeds.mnuActNewClick┤ │     │ 
                             SetDelayEventForMed...┤ │     │ 
                                  SetViewForCopy...┤ │     │ 
                          TfrmCopyOrders.cmdOKClick┤ │     │ 
                      TfrmCopyOrders.UMStillDelay┤ │ │     │ 
TfrmCopyOrders.fraEvntDelayListmlstEventsDblClick┤ │ │     │ 
                       TfrmCopyOrders.FormKeyDown┘ │ │     │ 
                                ExecuteChangeEvt...┤ │     │ 
                                    ExecuteDCOrders┘ │     │ 
                         TfrmOrders.mnuActDCClick┤   │     │ 
                           TfrmMeds.mnuActDCClick┘   │     │ 
                            TfrmOrders.SaveSignOrders┤     │ 
                          TfrmOrders.NotifyOrder...┘ │     │ 
                           TfrmOrders.mnuActSignClick┤     │ 
                 TfrmOrders.EventRealeasedOrder1Click┤     │ 
                         TfrmOrders.ResetOrderPage...┤     │ 
                         TfrmOrders.PtEvtCompleted...┤     │ 
                        TfrmOrders.RefreshToFirstItem┤     │ 
                              TfrmOrders.UMEventOccur┤     │ 
                          TfrmOrders.hdrOrdersMouseUp┘     │ 
                             TfrmOrders.MeasureColumnHeight┤ 
                          TfrmOrders.lstOrdersMeasureItem┘ │ 
                               TfrmOrders.lstOrdersDrawItem┘ 

Calls

Name Declaration Comments
TfrmOrders.GetStartStopText function GetStartStopText(StartTime: string; StopTime: string): string; -
LoadFlagReason procedure LoadFlagReason(Dest: TStrings; const ID: string); -
NameOfStatus function NameOfStatus(IEN: Integer): string; -

Called-By

Name Declaration Comments
TfrmOrders.GetPlainText function GetPlainText(AnOrder: TOrder; index: integer):string; -
TfrmOrders.lstOrdersDrawItem procedure lstOrdersDrawItem(Control: TWinControl; Index: Integer; TheRect: TRect; State: TOwnerDrawState); -
TfrmOrders.MeasureColumnHeight function MeasureColumnHeight(AnOrder: TOrder; Index: Integer; Column: integer):integer; -


Source

1366  function TfrmOrders.GetOrderText(AnOrder: TOrder; Index: integer; Column: integer): string;
1367  var
1368    AReason:  TStringlist;
1369    i: integer;
1370  begin
1371    if AnOrder <> nil then with AnOrder do
1372    begin
1373      case Column of
1374        0:
1375        begin
1376          result := EventName;
1377          if (Index > 0) and (result = TOrder(lstOrders.Items.Objects[Index - 1]).EventName) then result := '';
1378        end;
1379        1:
1380        begin
1381          result := DGroupName;
1382          if (Index > 0) and (result = TOrder(lstOrders.Items.Objects[Index - 1]).DGroupName) then result := '';
1383        end;
1384        2:
1385        begin
1386          result := Text;
1387          if Flagged then
1388          begin
1389            if Notifications.Active then
1390            begin
1391              AReason := TStringList.Create;
1392              try
1393                result := result + crlf;
1394                LoadFlagReason(AReason, ID);
1395                for i := 0 to AReason.Count - 1 do
1396                  result :=  result + AReason[i] + CRLF;
1397              finally
1398                AReason.Free;
1399              end;
1400            end
1401            else
1402              result := result + '  *Flagged*';
1403          end;
1404        end;
1405        3: result := GetStartStopText( StartTime, StopTime);
1406        4:
1407        begin
1408          result := MixedCase(ProviderName);
1409  //        result := Piece(result, ',', 1) + ',' + Copy(Piece(result, ',', 2), 1, 1);
1410  // CQ#15915
1411          result := Piece(result, ',', 1) + ',' + Piece(result, ',', 2);
1412        end;
1413        5: result := VerNurse;
1414        6: result := VerClerk;
1415        7: result := ChartRev;
1416        8: result := NameOfStatus(Status);
1417        9: result := MixedCase(Anorder.OrderLocName);
1418        //begin AGP change 26.52 display all location for orders.
1419          //result := MixedCase(Anorder.OrderLocName);
1420          //if (Index > 0) and (result = TOrder(lstOrders.Items.Objects[Index - 1]).OrderLocName) then result := '';
1421        //end;
1422      end;
1423    end;
1424  end;