Class

TfrmVisitType

Module

fVisitType

Last Modified

7/15/2014 3:26:36 PM

Scope

Interfaced

Inherits from

TfrmPCEBase

Declaration


TfrmVisitType = class(TfrmPCEBase)
  pnlTop: TPanel;
  splLeft: TSplitter;
  splRight: TSplitter;
  pnlLeft: TPanel;
  lstVTypeSection: TORListBox;
  pnlMiddle: TPanel;
  fraVisitRelated: TfraVisitRelated;
  pnlSC: TPanel;
  lblSCDisplay: TLabel;
  memSCDisplay: TCaptionMemo;
  pnlBottom: TPanel;
  btnAdd: TButton;
  btnDelete: TButton;
  btnPrimary: TButton;
  pnlBottomLeft: TPanel;
  lblProvider: TLabel;
  cboPtProvider: TORComboBox;
  pnlBottomRight: TPanel;
  lbProviders: TORListBox;
  lblCurrentProv: TLabel;
  lblVTypeSection: TLabel;
  pnlModifiers: TPanel;
  lbMods: TORListBox;
  lblMod: TLabel;
  pnlSection: TPanel;
  lbxVisits: TORListBox;
  lblVType: TLabel;
  procedure lstVTypeSectionClick(Sender: TObject);
  procedure FormCloseQuery(Sender: TObject; var CanClose: Boolean);
  procedure FormCreate(Sender: TObject);
  procedure btnAddClick(Sender: TObject);
  procedure btnDeleteClick(Sender: TObject);
  procedure btnPrimaryClick(Sender: TObject);
  procedure cboPtProviderDblClick(Sender: TObject);
  procedure cboPtProviderChange(Sender: TObject);
  procedure cboPtProviderNeedData(Sender: TObject;
    const StartFrom: String; Direction, InsertAt: Integer);
  procedure lbProvidersChange(Sender: TObject);
  procedure lbProvidersDblClick(Sender: TObject);
  procedure FormResize(Sender: TObject);
  procedure lbxVisitsClickCheck(Sender: TObject; Index: Integer);
  procedure lbModsClickCheck(Sender: TObject; Index: Integer);
  procedure lbxVisitsClick(Sender: TObject);
  procedure memSCDisplayEnter(Sender: TObject);
protected
  FSplitterMove: boolean;
  procedure ShowModifiers;
  procedure CheckModifiers;
private
  FChecking: boolean;
  FCheckingMods: boolean;
  FLastCPTCodes: string;
  FLastMods: string;
  procedure RefreshProviders;
  procedure UpdateProviderButtons;
public
  procedure MatchVType;
end;

DFM Objects


frmVisitType : TfrmVisitType
 ├btnOK : TBitBtn
 ├pnlTop : TPanel
 │ ├splLeft : TSplitter
 │ ├splRight : TSplitter
 │ ├pnlLeft : TPanel
 │ │ ├lblVTypeSection : TLabel
 │ │ └lstVTypeSection : TORListBox
 │ ├pnlModifiers : TPanel
 │ │ ├lblMod : TLabel
 │ │ └lbMods : TORListBox
 │ └pnlSection : TPanel
 │   ├lblVType : TLabel
 │   └lbxVisits : TORListBox
 ├pnlMiddle : TPanel
 │ ├fraVisitRelated : TfraVisitRelated
 │ │ └gbVisitRelatedTo : TGroupBox
 │ │   ├chkMSTYes : TCheckBox
 │ │   ├chkMSTNo : TCheckBox
 │ │   ├chkHNCYes : TCheckBox
 │ │   └chkHNCNo : TCheckBox
 │ └pnlSC : TPanel
 │   ├lblSCDisplay : TLabel
 │   └memSCDisplay : TCaptionMemo
 ├pnlBottom : TPanel
 │ ├btnAdd : TButton
 │ ├btnDelete : TButton
 │ ├btnPrimary : TButton
 │ ├pnlBottomLeft : TPanel
 │ │ ├lblProvider : TLabel
 │ │ └cboPtProvider : TORComboBox
 │ └pnlBottomRight : TPanel
 │   ├lblCurrentProv : TLabel
 │   └lbProviders : TORListBox
 ├btnCancel : TBitBtn
 └amgrMain : TVA508AccessibilityManager

Class Hierarchy


Class Fields

Name Type Scope Comments
btnAdd TButton Public/Published -
btnDelete TButton Public/Published -
btnPrimary TButton Public/Published -
cboPtProvider TORComboBox Public/Published -
FChecking Boolean Private -
FCheckingMods Boolean Private -
FLastCPTCodes UnicodeString Private -
FLastMods UnicodeString Private -
fraVisitRelated TfraVisitRelated Public/Published -
FSplitterMove Boolean Protected -
lblCurrentProv TLabel Public/Published -
lblMod TLabel Public/Published -
lblProvider TLabel Public/Published -
lblSCDisplay TLabel Public/Published -
lblVType TLabel Public/Published -
lblVTypeSection TLabel Public/Published -
lbMods TORListBox Public/Published -
lbProviders TORListBox Public/Published -
lbxVisits TORListBox Public/Published -
lstVTypeSection TORListBox Public/Published -
memSCDisplay TCaptionMemo Public/Published -
pnlBottom TPanel Public/Published -
pnlBottomLeft TPanel Public/Published -
pnlBottomRight TPanel Public/Published -
pnlLeft TPanel Public/Published -
pnlMiddle TPanel Public/Published -
pnlModifiers TPanel Public/Published -
pnlSC TPanel Public/Published -
pnlSection TPanel Public/Published -
pnlTop TPanel Public/Published -
splLeft TSplitter Public/Published -
splRight TSplitter Public/Published -

Methods

Name Declaration Scope Comments
btnAddClick procedure btnAddClick(Sender: TObject); Public/Published -
btnDeleteClick procedure btnDeleteClick(Sender: TObject); Public/Published -
btnPrimaryClick procedure btnPrimaryClick(Sender: TObject); Public/Published -
cboPtProviderChange procedure cboPtProviderChange(Sender: TObject); Public/Published -
cboPtProviderDblClick procedure cboPtProviderDblClick(Sender: TObject); Public/Published -
cboPtProviderNeedData procedure cboPtProviderNeedData(Sender: TObject; const StartFrom: String; Direction, InsertAt: Integer); Public/Published -
CheckModifiers procedure CheckModifiers; Protected -
FormCloseQuery procedure FormCloseQuery(Sender: TObject; var CanClose: Boolean); Public/Published -
FormCreate procedure FormCreate(Sender: TObject); Public/Published -
FormResize procedure FormResize(Sender: TObject); Public/Published -
lbModsClickCheck procedure lbModsClickCheck(Sender: TObject; Index: Integer); Public/Published -
lbProvidersChange procedure lbProvidersChange(Sender: TObject); Public/Published -
lbProvidersDblClick procedure lbProvidersDblClick(Sender: TObject); Public/Published -
lbxVisitsClick procedure lbxVisitsClick(Sender: TObject); Public/Published -
lbxVisitsClickCheck procedure lbxVisitsClickCheck(Sender: TObject; Index: Integer); Public/Published -
lstVTypeSectionClick procedure lstVTypeSectionClick(Sender: TObject); Public/Published -
MatchVType procedure MatchVType; Public -
memSCDisplayEnter procedure memSCDisplayEnter(Sender: TObject); Public/Published -
RefreshProviders procedure RefreshProviders; Private
Function ExposureAnswered: Boolean;
begin
  result := false;
  //if SC answered set result = true
end;
ShowModifiers procedure ShowModifiers; Protected Needed,
UpdateProviderButtons procedure UpdateProviderButtons; Private
Procedure TfrmVisitType.SynchEncounterProvider;
// add the Encounter.Provider if this note is for the current encounter
var
  ProviderFound, PrimaryFound: Boolean;
  i: Integer;
  AProvider: TPCEProvider;
begin
  if (FloatToStrF(uEncPCEData.DateTime, ffFixed, 15, 4) =      // compensate rounding errors
      FloatToStrF(Encounter.DateTime,   ffFixed, 15, 4)) and
     (uEncPCEData.Location = Encounter.Location) and
     (Encounter.Provider > 0) then
  begin
    ProviderFound := False;
    PrimaryFound := False;
    for i := 0 to ProviderLst.Count - 1 do
    begin
      AProvider := TPCEProvider(ProviderLst.Items[i]);
      if AProvider.IEN = Encounter.Provider then ProviderFound := True;
      if AProvider.Primary = '1' then PrimaryFound := True;
    end;
    if not ProviderFound then
    begin
      AProvider := TPCEProvider.Create;
      AProvider.IEN := Encounter.Provider;
      AProvider.Name := ExternalName(Encounter.Provider, FN_NEW_PERSON);
      if not PrimaryFound then
      begin
        AProvider.Primary := '1';
        uProvider := Encounter.Provider;
      end
      else AProvider.Primary := '0';
      AProvider.Delete := False;
      ProviderLst.Add(AProvider);
    end;
  end;
end;

Referenced By (3)

Module (line) Referrer Type
fEncounterFrame (259) - Read
fVisitType (72) frmVisitType Read
fVisitType (544) - Read