Procedure

TfrmOrders.RefreshOrderList

Module

fOrders

Last Modified

7/15/2014 3:26:42 PM

Visibility

Private

Owner

TfrmOrders

Declaration

procedure RefreshOrderList(FromServer: Boolean; APtEvtID: string = '');

Calls Hierarchy


TfrmOrders.RefreshOrderList
 ├LoadOrdersAbbr
 │ ├ClearOrders
 │ ├LoadDGroupMap
 │ ├ExpiredOrdersStartDT
 │ ├FMNow
 │ └SeqOfDGroup
 │   └LoadDGroupMap
 ├ClearOrders
 ├LoadOrdersAbbr
 │ ├LoadDGroupMap
 │ ├FMNow
 │ └SeqOfDGroup...
 ├TfrmOrders.ExpandEventSection
 ├TfrmOrders.CompressEventSection
 ├SortOrders
 │ ├InverseByGroup
 │ │ └TChanges.Exist
 │ ├ForwardByGroup
 │ │ └TChanges.Exist
 │ ├InverseChrono
 │ └ForwardChrono
 ├TfrmOrders.AddToListBox
 │ └TfrmOrders.GetPlainText
 │   └TfrmOrders.GetOrderText
 │     ├LoadFlagReason
 │     ├TfrmOrders.GetStartStopText
 │     └NameOfStatus
 └DGroupAll

Called-By Hierarchy


                            TfrmOrders.RefreshOrderList
                               TfrmOrders.NotifyOrder┤ 
                               TfrmFrame.UMNewOrder┘ │ 
                              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.LoadSizesForUser┤         │ │ │ │ │ 
    TfrmFrame.LoadUserPreferences┘ │         │ │ │ │ │ 
           TfrmFrame.UMInitiate┘   │         │ │ │ │ │ 
         TfrmFrame.mnuFontSizeClick┘         │ │ │ │ │ 
                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┘ 

Calls

Name Declaration Comments
TfrmOrders.AddToListBox procedure AddToListBox(AnOrderList: TList); -
ClearOrders procedure ClearOrders(AList: TList); -
TfrmOrders.CompressEventSection procedure CompressEventSection; -
DGroupAll function DGroupAll: Integer; -
TfrmOrders.ExpandEventSection procedure ExpandEventSection; -
LoadOrdersAbbr procedure LoadOrdersAbbr(Dest: TList; AView: TOrderView; APtEvtID: string); overload; -
LoadOrdersAbbr procedure LoadOrdersAbbr(DestDC,DestRL: TList; AView: TOrderView; APtEvtID: string); overload; -
SortOrders procedure SortOrders(AList: TList; ByGroup, InvChron: Boolean); -

Called-By

Name Declaration Comments
TfrmOrders.EventRealeasedOrder1Click procedure EventRealeasedOrder1Click(Sender: TObject); -
TfrmOrders.hdrOrdersMouseUp procedure hdrOrdersMouseUp(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer); -
TfrmOrders.lstSheetsClick procedure lstSheetsClick(Sender: TObject); -
TfrmOrders.mnuActSignClick procedure mnuActSignClick(Sender: TObject); -
TfrmOrders.mnuViewCustomClick procedure mnuViewCustomClick(Sender: TObject); -
TfrmOrders.mnuViewDfltShowClick procedure mnuViewDfltShowClick(Sender: TObject); -
TfrmOrders.NotifyOrder procedure NotifyOrder(OrderAction: Integer; AnOrder: TOrder); override; -
TfrmOrders.PtEvtCompleted function PtEvtCompleted(APtEvtID: integer; APtEvtName: string; FromMeds: boolean = False; Signing: boolean = False): boolean; -
TfrmOrders.RefreshToFirstItem procedure RefreshToFirstItem; -
TfrmOrders.ResetOrderPage procedure ResetOrderPage(AnEvent: TOrderDelayEvent; ADlgLst: TStringList; IsRealeaseNow: boolean); -
TfrmOrders.SaveSignOrders procedure SaveSignOrders; -
TfrmOrders.SetOrderView procedure SetOrderView(AFilter, ADGroup: Integer; const AViewName: string; NotifSort: Boolean); -
TfrmOrders.UMEventOccur procedure UMEventOccur(var Message: TMessage); message UM_EVENTOCCUR; -


Source

732   procedure TfrmOrders.RefreshOrderList(FromServer: Boolean; APtEvtID: string);
733   var
734     i: Integer;
735   begin
736     with FCurrentView do
737     begin
738       if EventDelay.EventIFN > 0 then
739         FCompress := False;
740       RedrawSuspend(lstOrders.Handle);
741       lstOrders.Clear;
742       if FromServer then
743       begin
744         StatusText('Retrieving orders list...');
745         if not FFromDCRelease then
746           LoadOrdersAbbr(uOrderList, FCurrentView, APtEvtID)
747         else
748         begin
749           ClearOrders(uOrderList);
750           uEvtDCList.Clear;
751           uEvtRLList.Clear;
752           LoadOrdersAbbr(uEvtDCList,uEvtRLList,FCurrentView,APtEvtID);
753         end;
754       end;
755       if ((Length(APtEvtID)>0) or (FCurrentView.Filter in [15,16,17,24]) or  (FCurrentView.EventDelay.PtEventIFN>0))
756         and ((not FCompress) or (lstSheets.ItemIndex<0)) and (not FFromDCRelease) then ExpandEventSection
757       else CompressEventSection;
758       if not FFromDCRelease then
759       begin
760         if FRightAfterWriteOrderBox and (EventDelay.EventIFN>0) then
761         begin
762           SortOrders(uOrderList,False,True);
763           FRightAfterWriteOrderBox := False;
764         end else
765           SortOrders(uOrderList, ByService, InvChrono);
766         AddToListBox(uOrderList);
767       end;
768       if FFromDCRelease then
769       begin
770         if uEvtRLList.Count > 0 then
771         begin
772           SortOrders(uEvtRLList,True,True);
773           for i := 0 to uEvtRLList.Count - 1 do
774             uOrderList.Add(TOrder(uEvtRLList[i]));
775         end;
776         if uEvtDCList.Count > 0 then
777         begin
778           SortOrders(uEvtDCList,True,True);
779           for i := 0 to uEvtDCList.Count - 1 do
780             uOrderList.Add(TOrder(uEvtDCList[i]));   
781         end;
782         AddToListBox(uOrderList);
783       end;
784       RedrawActivate(lstOrders.Handle);
785       lblOrders.Caption := ViewName;
786       lstOrders.Caption := ViewName;
787       imgHide.Visible := not ((Filter in [1, 2]) and (DGroup = DGroupAll));
788       StatusText('');
789     end;
790   end;