Class

TfrmSurgery

Module

fSurgery

Last Modified

7/15/2014 3:26:38 PM

Scope

Interfaced

Inherits from

TfrmHSplit

Declaration


TfrmSurgery = class(TfrmHSplit)
  mnuNotes: TMainMenu;
  mnuView: TMenuItem;
  mnuViewChart: TMenuItem;
  mnuChartReports: TMenuItem;
  mnuChartLabs: TMenuItem;
  mnuChartDCSumm: TMenuItem;
  mnuChartCslts: TMenuItem;
  mnuChartNotes: TMenuItem;
  mnuChartOrders: TMenuItem;
  mnuChartMeds: TMenuItem;
  mnuChartProbs: TMenuItem;
  mnuChartCover: TMenuItem;
  Z1: TMenuItem;
  mnuViewDetail: TMenuItem;
  mnuAct: TMenuItem;
  mnuActNew: TMenuItem;
  Z2: TMenuItem;
  mnuActSave: TMenuItem;
  mnuActDelete: TMenuItem;
  mnuActEdit: TMenuItem;
  mnuActSign: TMenuItem;
  mnuActAddend: TMenuItem;
  lblCases: TOROffsetLabel;
  pnlRead: TPanel;
  lblTitle: TOROffsetLabel;
  memSurgery: TRichEdit;
  pnlWrite: TPanel;
  memNewNote: TRichEdit;
  Z3: TMenuItem;
  mnuViewAll: TMenuItem;
  mnuViewBySurgeon: TMenuItem;
  mnuViewByDate: TMenuItem;
  mnuViewUncosigned: TMenuItem;
  mnuViewUnsigned: TMenuItem;
  mnuActSignList: TMenuItem;
  cmdNewNote: TORAlignButton;
  lblSpace1: TLabel;
  popNoteMemo: TPopupMenu;
  popNoteMemoCut: TMenuItem;
  popNoteMemoCopy: TMenuItem;
  popNoteMemoPaste: TMenuItem;
  Z10: TMenuItem;
  popNoteMemoSignList: TMenuItem;
  popNoteMemoDelete: TMenuItem;
  popNoteMemoEdit: TMenuItem;
  popNoteMemoSave: TMenuItem;
  popNoteMemoSign: TMenuItem;
  popNoteList: TPopupMenu;
  popNoteListAll: TMenuItem;
  popNoteListByDate: TMenuItem;
  mnuActIdentifyAddlSigners: TMenuItem;
  popNoteMemoAddlSign: TMenuItem;
  Z11: TMenuItem;
  popNoteMemoSpell: TMenuItem;
  popNoteMemoGrammar: TMenuItem;
  mnuViewCustom: TMenuItem;
  N1: TMenuItem;
  mnuViewSaveAsDefault: TMenuItem;
  ReturntoDefault1: TMenuItem;
  pnlDrawers: TPanel;
  splDrawers: TSplitter;
  popNoteMemoTemplate: TMenuItem;
  Z12: TMenuItem;
  mnuOptions: TMenuItem;
  mnuEditTemplates: TMenuItem;
  mnuNewTemplate: TMenuItem;
  N2: TMenuItem;
  mnuEditSharedTemplates: TMenuItem;
  mnuNewSharedTemplate: TMenuItem;
  popNoteMemoAddend: TMenuItem;
  pnlFields: TPanel;
  lblNewTitle: TLabel;
  lblRefDate: TLabel;
  lblAuthor: TLabel;
  lblVisit: TLabel;
  lblCosigner: TLabel;
  cmdChange: TButton;
  lblSubject: TLabel;
  txtSubject: TCaptionEdit;
  timAutoSave: TTimer;
  popNoteMemoPaste2: TMenuItem;
  popNoteMemoReformat: TMenuItem;
  Z4: TMenuItem;
  mnuActChange: TMenuItem;
  mnuActLoadBoiler: TMenuItem;
  bvlNewTitle: TBevel;
  popNoteMemoSaveContinue: TMenuItem;
  N3: TMenuItem;
  mnuEditDialgFields: TMenuItem;
  N4: TMenuItem;
  popNoteListExpandSelected: TMenuItem;
  popNoteListExpandAll: TMenuItem;
  popNoteListCollapseSelected: TMenuItem;
  popNoteListCollapseAll: TMenuItem;
  popNoteListCustom: TMenuItem;
  mnuActDetachFromIDParent: TMenuItem;
  N5: TMenuItem;
  popNoteListDetachFromIDParent: TMenuItem;
  popNoteListAddIDEntry: TMenuItem;
  mnuActAddIDEntry: TMenuItem;
  mnuIconLegend: TMenuItem;
  N6: TMenuItem;
  popNoteMemoFind: TMenuItem;
  dlgFindText: TFindDialog;
  dlgReplaceText: TReplaceDialog;
  popNoteMemoReplace: TMenuItem;
  N7: TMenuItem;
  tvSurgery: TORTreeView;
  mnuChartSurgery: TMenuItem;
  lstNotes: TORListBox;
  sptVert: TSplitter;
  memPCEShow: TRichEdit;
  cmdPCE: TORAlignButton;
  popNoteListBySurgeon: TMenuItem;
  popNoteListUnsigned: TMenuItem;
  popNoteListUncosigned: TMenuItem;
  N8: TMenuItem;
  popNoteMemoPreview: TMenuItem;
  popNoteMemoInsTemplate: TMenuItem;
  popNoteMemoEncounter: TMenuItem;
  mnuViewInformation: TMenuItem;
  mnuViewDemo: TMenuItem;
  mnuViewVisits: TMenuItem;
  mnuViewPrimaryCare: TMenuItem;
  mnuViewMyHealtheVet: TMenuItem;
  mnuInsurance: TMenuItem;
  mnuViewFlags: TMenuItem;
  mnuViewReminders: TMenuItem;
  mnuViewRemoteData: TMenuItem;
  mnuViewPostings: TMenuItem;
  imgLblImages: TVA508ImageListLabeler;
  imgLblSurgery: TVA508ImageListLabeler;
  procedure mnuChartTabClick(Sender: TObject);
  procedure pnlRightResize(Sender: TObject);
  procedure cmdNewNoteClick(Sender: TObject);
  procedure mnuActNewClick(Sender: TObject);
  procedure mnuActSaveClick(Sender: TObject);
  procedure mnuViewClick(Sender: TObject);
  procedure mnuActAddendClick(Sender: TObject);
  procedure mnuActSignListClick(Sender: TObject);
  procedure mnuActDeleteClick(Sender: TObject);
  procedure mnuActEditClick(Sender: TObject);
  procedure mnuActSignClick(Sender: TObject);
  procedure cmdPCEClick(Sender: TObject);
  procedure popNoteMemoCutClick(Sender: TObject);
  procedure popNoteMemoCopyClick(Sender: TObject);
  procedure popNoteMemoPasteClick(Sender: TObject);
  procedure popNoteMemoPopup(Sender: TObject);
  procedure pnlWriteResize(Sender: TObject);
  procedure FormCreate(Sender: TObject);
  procedure mnuViewDetailClick(Sender: TObject);
  procedure FormClose(Sender: TObject; var Action: TCloseAction);
  procedure mnuActIdentifyAddlSignersClick(Sender: TObject);
  procedure popNoteMemoAddlSignClick(Sender: TObject);
  procedure popNoteMemoSpellClick(Sender: TObject);
  procedure popNoteMemoGrammarClick(Sender: TObject);
  procedure mnuViewSaveAsDefaultClick(Sender: TObject);
  procedure mnuViewReturntoDefaultClick(Sender: TObject);
  procedure popNoteMemoTemplateClick(Sender: TObject);
  procedure mnuEditTemplatesClick(Sender: TObject);
  procedure mnuNewTemplateClick(Sender: TObject);
  procedure mnuEditSharedTemplatesClick(Sender: TObject);
  procedure mnuNewSharedTemplateClick(Sender: TObject);
  procedure mnuOptionsClick(Sender: TObject);
  procedure FormDestroy(Sender: TObject);
  procedure cmdChangeClick(Sender: TObject);
  procedure pnlFieldsResize(Sender: TObject);
  procedure timAutoSaveTimer(Sender: TObject);
  procedure memNewNoteChange(Sender: TObject);
  procedure popNoteMemoReformatClick(Sender: TObject);
  procedure mnuActChangeClick(Sender: TObject);
  procedure mnuActLoadBoilerClick(Sender: TObject);
  procedure popNoteMemoSaveContinueClick(Sender: TObject);
  procedure mnuEditDialgFieldsClick(Sender: TObject);
  procedure popNoteListExpandAllClick(Sender: TObject);
  procedure popNoteListCollapseAllClick(Sender: TObject);
  procedure popNoteListExpandSelectedClick(Sender: TObject);
  procedure popNoteListCollapseSelectedClick(Sender: TObject);
  procedure popNoteListPopup(Sender: TObject);
  procedure mnuIconLegendClick(Sender: TObject);
  procedure popNoteMemoFindClick(Sender: TObject);
  procedure dlgFindTextFind(Sender: TObject);
  procedure popNoteMemoReplaceClick(Sender: TObject);
  procedure dlgReplaceTextReplace(Sender: TObject);
  procedure dlgReplaceTextFind(Sender: TObject);
  procedure tvSurgeryClick(Sender: TObject);
  procedure tvSurgeryChange(Sender: TObject; Node: TTreeNode);
  procedure tvSurgeryExpanded(Sender: TObject; Node: TTreeNode);
  procedure tvSurgeryCollapsed(Sender: TObject; Node: TTreeNode);
  procedure lstNotesClick(Sender: TObject);
  procedure memNewNoteKeyDown(Sender: TObject; var Key: Word;
    Shift: TShiftState);
  procedure sptHorzCanResize(Sender: TObject; var NewSize: Integer; var Accept: Boolean);
  procedure popNoteMemoPreviewClick(Sender: TObject);
  procedure popNoteMemoInsTemplateClick(Sender: TObject);
  procedure ViewInfo(Sender: TObject);
  procedure mnuViewInformationClick(Sender: TObject);
private
  FEditingIndex: Integer;                      // index of note being currently edited
  FCurrentContext: TSurgCaseContext;
  FDefaultContext: TSurgCaseContext;
  FImageFlag: TBitmap;
  FCaseList: TStringList;
  FChanged: Boolean;                           // true if any text has changed in the note
  FEditCtrl: TCustomEdit;
  FSilent: Boolean;
  FEditNote: TEditNoteRec;
  FVerifyNoteTitle: Integer;
  FConfirmed: boolean;
  FLastNoteID: string;
  FEditingNotePCEObj: boolean;
  FDeleted: boolean;
  procedure ClearEditControls;
  procedure DoAutoSave(Suppress: integer = 1);
  function GetTitleText(AnIndex: Integer): string;
  procedure InsertAddendum;
  procedure InsertNewNote(IsIDChild: boolean; AnIDParent: integer);
  function LacksRequiredForCreate: Boolean;
  procedure LoadForEdit;
  procedure  LoadSurgeryCases;
  procedure  UpdateTreeView(DocList: TStringList; Tree: TORTreeView);
  procedure SetViewContext(AContext: TSurgCaseContext);
  function GetDrawers: TfrmDrawers;
  procedure SetEditingIndex(const Value: Integer);
  property EditingIndex: Integer read FEditingIndex write SetEditingIndex;
  procedure ProcessNotifications;
  function SetSurgTreeLabel(AContext: TSurgCaseContext): string;
  procedure RemovePCEFromChanges(IEN: Int64; AVisitStr: string = '');
  procedure SaveEditedNote(var Saved: Boolean);
  procedure SaveCurrentNote(var Saved: Boolean);
  procedure SetSubjectVisible(ShouldShow: Boolean);
  procedure ShowPCEControls(ShouldShow: Boolean);
  function StartNewEdit(NewNoteType: integer): Boolean;
  //function CanFinishReminder: boolean;
  procedure DisplayPCE;
  function VerifyNoteTitle: Boolean;
  procedure ShowPCEButtons(Editing: boolean);
  procedure EnableDisableMenus(IsTIUDocument: boolean);
public
  function AllowContextChange(var WhyNot: string): Boolean; override;
  procedure ClearPtData; override;
  procedure DisplayPage; override;
  procedure RequestPrint; override;
  procedure SetFontSize(NewFontSize: Integer); override;
  procedure SaveSignItem(const ItemID, ESCode: string);
  procedure AssignRemForm;
published
  property Drawers: TfrmDrawers read GetDrawers; // Keep Drawers published
end;

DFM Objects


frmSurgery : TfrmSurgery
 ├shpPageBottom : TShape
 ├sptHorz : TSplitter
 ├pnlLeft : TPanel
 │ ├lblCases : TOROffsetLabel
 │ ├lblSpace1 : TLabel
 │ ├cmdNewNote : TORAlignButton
 │ ├cmdPCE : TORAlignButton
 │ └pnlDrawers : TPanel
 │   ├splDrawers : TSplitter
 │   ├lstNotes : TORListBox
 │   └tvSurgery : TORTreeView
 ├pnlRight : TPanel
 │ ├sptVert : TSplitter
 │ ├pnlRead : TPanel
 │ │ ├lblTitle : TOROffsetLabel
 │ │ └memSurgery : TRichEdit
 │ ├memPCEShow : TRichEdit
 │ └pnlWrite : TPanel
 │   ├memNewNote : TRichEdit
 │   └pnlFields : TPanel
 │     ├bvlNewTitle : TBevel
 │     ├lblRefDate : TLabel
 │     ├lblAuthor : TLabel
 │     ├lblVisit : TLabel
 │     ├lblCosigner : TLabel
 │     ├lblSubject : TLabel
 │     ├lblNewTitle : TLabel
 │     ├cmdChange : TButton
 │     └txtSubject : TCaptionEdit
 ├amgrMain : TVA508AccessibilityManager
 ├mnuNotes : TMainMenu
 │ ├mnuView : TMenuItem
 │ │ ├mnuViewChart : TMenuItem
 │ │ │ ├mnuChartCover : TMenuItem
 │ │ │ ├mnuChartProbs : TMenuItem
 │ │ │ ├mnuChartMeds : TMenuItem
 │ │ │ ├mnuChartOrders : TMenuItem
 │ │ │ ├mnuChartNotes : TMenuItem
 │ │ │ ├mnuChartCslts : TMenuItem
 │ │ │ ├mnuChartSurgery : TMenuItem
 │ │ │ ├mnuChartDCSumm : TMenuItem
 │ │ │ ├mnuChartLabs : TMenuItem
 │ │ │ └mnuChartReports : TMenuItem
 │ │ ├mnuViewInformation : TMenuItem
 │ │ │ ├mnuViewDemo : TMenuItem
 │ │ │ ├mnuViewVisits : TMenuItem
 │ │ │ ├mnuViewPrimaryCare : TMenuItem
 │ │ │ ├mnuViewMyHealtheVet : TMenuItem
 │ │ │ ├mnuInsurance : TMenuItem
 │ │ │ ├mnuViewFlags : TMenuItem
 │ │ │ ├mnuViewRemoteData : TMenuItem
 │ │ │ ├mnuViewReminders : TMenuItem
 │ │ │ └mnuViewPostings : TMenuItem
 │ │ ├Z3 : TMenuItem
 │ │ ├mnuViewAll : TMenuItem
 │ │ ├mnuViewBySurgeon : TMenuItem
 │ │ ├mnuViewByDate : TMenuItem
 │ │ ├mnuViewUncosigned : TMenuItem
 │ │ ├mnuViewUnsigned : TMenuItem
 │ │ ├mnuViewCustom : TMenuItem
 │ │ ├N1 : TMenuItem
 │ │ ├mnuViewSaveAsDefault : TMenuItem
 │ │ ├ReturntoDefault1 : TMenuItem
 │ │ ├Z1 : TMenuItem
 │ │ ├mnuViewDetail : TMenuItem
 │ │ ├N6 : TMenuItem
 │ │ └mnuIconLegend : TMenuItem
 │ ├mnuAct : TMenuItem
 │ │ ├mnuActNew : TMenuItem
 │ │ ├mnuActAddend : TMenuItem
 │ │ ├mnuActAddIDEntry : TMenuItem
 │ │ ├mnuActDetachFromIDParent : TMenuItem
 │ │ ├Z4 : TMenuItem
 │ │ ├mnuActChange : TMenuItem
 │ │ ├mnuActLoadBoiler : TMenuItem
 │ │ ├Z2 : TMenuItem
 │ │ ├mnuActSignList : TMenuItem
 │ │ ├mnuActDelete : TMenuItem
 │ │ ├mnuActEdit : TMenuItem
 │ │ ├mnuActSave : TMenuItem
 │ │ ├mnuActSign : TMenuItem
 │ │ └mnuActIdentifyAddlSigners : TMenuItem
 │ └mnuOptions : TMenuItem
 │   ├mnuEditTemplates : TMenuItem
 │   ├mnuNewTemplate : TMenuItem
 │   ├N2 : TMenuItem
 │   ├mnuEditSharedTemplates : TMenuItem
 │   ├mnuNewSharedTemplate : TMenuItem
 │   ├N3 : TMenuItem
 │   └mnuEditDialgFields : TMenuItem
 ├popNoteMemo : TPopupMenu
 │ ├popNoteMemoCut : TMenuItem
 │ ├popNoteMemoCopy : TMenuItem
 │ ├popNoteMemoPaste : TMenuItem
 │ ├popNoteMemoPaste2 : TMenuItem
 │ ├popNoteMemoReformat : TMenuItem
 │ ├popNoteMemoSaveContinue : TMenuItem
 │ ├Z11 : TMenuItem
 │ ├popNoteMemoFind : TMenuItem
 │ ├popNoteMemoReplace : TMenuItem
 │ ├N7 : TMenuItem
 │ ├popNoteMemoGrammar : TMenuItem
 │ ├popNoteMemoSpell : TMenuItem
 │ ├Z12 : TMenuItem
 │ ├popNoteMemoTemplate : TMenuItem
 │ ├Z10 : TMenuItem
 │ ├popNoteMemoSignList : TMenuItem
 │ ├popNoteMemoDelete : TMenuItem
 │ ├popNoteMemoEdit : TMenuItem
 │ ├popNoteMemoAddend : TMenuItem
 │ ├popNoteMemoSave : TMenuItem
 │ ├popNoteMemoSign : TMenuItem
 │ ├popNoteMemoAddlSign : TMenuItem
 │ ├N8 : TMenuItem
 │ ├popNoteMemoPreview : TMenuItem
 │ ├popNoteMemoInsTemplate : TMenuItem
 │ └popNoteMemoEncounter : TMenuItem
 ├popNoteList : TPopupMenu
 │ ├popNoteListAll : TMenuItem
 │ ├popNoteListBySurgeon : TMenuItem
 │ ├popNoteListByDate : TMenuItem
 │ ├popNoteListUncosigned : TMenuItem
 │ ├popNoteListUnsigned : TMenuItem
 │ ├popNoteListCustom : TMenuItem
 │ ├N4 : TMenuItem
 │ ├popNoteListExpandSelected : TMenuItem
 │ ├popNoteListExpandAll : TMenuItem
 │ ├popNoteListCollapseSelected : TMenuItem
 │ ├popNoteListCollapseAll : TMenuItem
 │ ├N5 : TMenuItem
 │ ├popNoteListAddIDEntry : TMenuItem
 │ └popNoteListDetachFromIDParent : TMenuItem
 ├timAutoSave : TTimer
 ├dlgFindText : TFindDialog
 ├dlgReplaceText : TReplaceDialog
 ├imgLblImages : TVA508ImageListLabeler
 └imgLblSurgery : TVA508ImageListLabeler

Class Hierarchy


Class Fields

Name Type Scope Comments
bvlNewTitle TBevel Public/Published -
cmdChange TButton Public/Published -
cmdNewNote TORAlignButton Public/Published -
cmdPCE TORAlignButton Public/Published -
dlgFindText TFindDialog Public/Published -
dlgReplaceText TReplaceDialog Public/Published -
FCaseList TStringList Private -
FChanged Boolean Private True if any text has changed in the note
FConfirmed Boolean Private -
FCurrentContext Private -
FDefaultContext Private -
FDeleted Boolean Private -
FEditCtrl Simple (unknown) Private -
FEditingIndex Integer Private Index of note being currently edited
FEditingNotePCEObj Boolean Private -
FEditNote Private -
FImageFlag TBitmap Private -
FLastNoteID UnicodeString Private -
FSilent Boolean Private -
FVerifyNoteTitle Integer Private -
imgLblImages Simple (unknown) Public/Published -
imgLblSurgery Simple (unknown) Public/Published -
lblAuthor TLabel Public/Published -
lblCases TOROffsetLabel Public/Published -
lblCosigner TLabel Public/Published -
lblNewTitle TLabel Public/Published -
lblRefDate TLabel Public/Published -
lblSpace1 TLabel Public/Published -
lblSubject TLabel Public/Published -
lblTitle TOROffsetLabel Public/Published -
lblVisit TLabel Public/Published -
lstNotes TORListBox Public/Published -
memNewNote TRichEdit Public/Published -
memPCEShow TRichEdit Public/Published -
memSurgery TRichEdit Public/Published -
mnuAct TMenuItem Public/Published -
mnuActAddend TMenuItem Public/Published -
mnuActAddIDEntry TMenuItem Public/Published -
mnuActChange TMenuItem Public/Published -
mnuActDelete TMenuItem Public/Published -
mnuActDetachFromIDParent TMenuItem Public/Published -
mnuActEdit TMenuItem Public/Published -
mnuActIdentifyAddlSigners TMenuItem Public/Published -
mnuActLoadBoiler TMenuItem Public/Published -
mnuActNew TMenuItem Public/Published -
mnuActSave TMenuItem Public/Published -
mnuActSign TMenuItem Public/Published -
mnuActSignList TMenuItem Public/Published -
mnuChartCover TMenuItem Public/Published -
mnuChartCslts TMenuItem Public/Published -
mnuChartDCSumm TMenuItem Public/Published -
mnuChartLabs TMenuItem Public/Published -
mnuChartMeds TMenuItem Public/Published -
mnuChartNotes TMenuItem Public/Published -
mnuChartOrders TMenuItem Public/Published -
mnuChartProbs TMenuItem Public/Published -
mnuChartReports TMenuItem Public/Published -
mnuChartSurgery TMenuItem Public/Published -
mnuEditDialgFields TMenuItem Public/Published -
mnuEditSharedTemplates TMenuItem Public/Published -
mnuEditTemplates TMenuItem Public/Published -
mnuIconLegend TMenuItem Public/Published -
mnuInsurance TMenuItem Public/Published -
mnuNewSharedTemplate TMenuItem Public/Published -
mnuNewTemplate TMenuItem Public/Published -
mnuNotes Simple (unknown) Public/Published -
mnuOptions TMenuItem Public/Published -
mnuView TMenuItem Public/Published -
mnuViewAll TMenuItem Public/Published -
mnuViewByDate TMenuItem Public/Published -
mnuViewBySurgeon TMenuItem Public/Published -
mnuViewChart TMenuItem Public/Published -
mnuViewCustom TMenuItem Public/Published -
mnuViewDemo TMenuItem Public/Published -
mnuViewDetail TMenuItem Public/Published -
mnuViewFlags TMenuItem Public/Published -
mnuViewInformation TMenuItem Public/Published -
mnuViewMyHealtheVet TMenuItem Public/Published -
mnuViewPostings TMenuItem Public/Published -
mnuViewPrimaryCare TMenuItem Public/Published -
mnuViewReminders TMenuItem Public/Published -
mnuViewRemoteData TMenuItem Public/Published -
mnuViewSaveAsDefault TMenuItem Public/Published -
mnuViewUncosigned TMenuItem Public/Published -
mnuViewUnsigned TMenuItem Public/Published -
mnuViewVisits TMenuItem Public/Published -
N1 TMenuItem Public/Published -
N2 TMenuItem Public/Published -
N3 TMenuItem Public/Published -
N4 TMenuItem Public/Published -
N5 TMenuItem Public/Published -
N6 TMenuItem Public/Published -
N7 TMenuItem Public/Published -
N8 TMenuItem Public/Published -
pnlDrawers TPanel Public/Published -
pnlFields TPanel Public/Published -
pnlRead TPanel Public/Published -
pnlWrite TPanel Public/Published -
popNoteList TPopupMenu Public/Published -
popNoteListAddIDEntry TMenuItem Public/Published -
popNoteListAll TMenuItem Public/Published -
popNoteListByDate TMenuItem Public/Published -
popNoteListBySurgeon TMenuItem Public/Published -
popNoteListCollapseAll TMenuItem Public/Published -
popNoteListCollapseSelected TMenuItem Public/Published -
popNoteListCustom TMenuItem Public/Published -
popNoteListDetachFromIDParent TMenuItem Public/Published -
popNoteListExpandAll TMenuItem Public/Published -
popNoteListExpandSelected TMenuItem Public/Published -
popNoteListUncosigned TMenuItem Public/Published -
popNoteListUnsigned TMenuItem Public/Published -
popNoteMemo TPopupMenu Public/Published -
popNoteMemoAddend TMenuItem Public/Published -
popNoteMemoAddlSign TMenuItem Public/Published -
popNoteMemoCopy TMenuItem Public/Published -
popNoteMemoCut TMenuItem Public/Published -
popNoteMemoDelete TMenuItem Public/Published -
popNoteMemoEdit TMenuItem Public/Published -
popNoteMemoEncounter TMenuItem Public/Published -
popNoteMemoFind TMenuItem Public/Published -
popNoteMemoGrammar TMenuItem Public/Published -
popNoteMemoInsTemplate TMenuItem Public/Published -
popNoteMemoPaste TMenuItem Public/Published -
popNoteMemoPaste2 TMenuItem Public/Published -
popNoteMemoPreview TMenuItem Public/Published -
popNoteMemoReformat TMenuItem Public/Published -
popNoteMemoReplace TMenuItem Public/Published -
popNoteMemoSave TMenuItem Public/Published -
popNoteMemoSaveContinue TMenuItem Public/Published -
popNoteMemoSign TMenuItem Public/Published -
popNoteMemoSignList TMenuItem Public/Published -
popNoteMemoSpell TMenuItem Public/Published -
popNoteMemoTemplate TMenuItem Public/Published -
ReturntoDefault1 TMenuItem Public/Published -
splDrawers TSplitter Public/Published -
sptVert TSplitter Public/Published -
timAutoSave TTimer Public/Published -
tvSurgery TORTreeView Public/Published -
txtSubject TCaptionEdit Public/Published -
Z1 TMenuItem Public/Published -
Z10 TMenuItem Public/Published -
Z11 TMenuItem Public/Published -
Z12 TMenuItem Public/Published -
Z2 TMenuItem Public/Published -
Z3 TMenuItem Public/Published -
Z4 TMenuItem Public/Published -

Properties

Name Type Scope Comments
Drawers TfrmDrawers Published Keep Drawers published
EditingIndex Integer Private -

Methods

Name Declaration Scope Comments
AllowContextChange function AllowContextChange(var WhyNot: string): Boolean; override; Public TPage common methods ---------------------------------------------------------------------
AssignRemForm procedure AssignRemForm; Public
Function TfrmSurgery.CanFinishReminder: boolean;
begin
  Result := False;
  if(EditingIndex < 0) then
    Result := FALSE
  else
    Result := (lstNotes.ItemIndex = EditingIndex);
end;
ClearEditControls procedure ClearEditControls; Private
General procedures ----------------------------------------------------------------------- 

 resets controls used for entering a new progress note
ClearPtData procedure ClearPtData; override; Public Clear all controls that contain patient specific information
cmdChangeClick procedure cmdChangeClick(Sender: TObject); Public/Published -
cmdNewNoteClick procedure cmdNewNoteClick(Sender: TObject); Public/Published
Left panel (selector) events ------------------------------------------------------------- 

 maps 'New Note' button to the New Progress Note menu item
cmdPCEClick procedure cmdPCEClick(Sender: TObject); Public/Published -
DisplayPage procedure DisplayPage; override; Public Causes page to be visible and conditionally executes initialization code
DisplayPCE procedure DisplayPCE; Private
Function CanFinishReminder: boolean;
displays PCE information if appropriate & enables/disabled editing of PCE data
dlgFindTextFind procedure dlgFindTextFind(Sender: TObject); Public/Published -
dlgReplaceTextFind procedure dlgReplaceTextFind(Sender: TObject); Public/Published -
dlgReplaceTextReplace procedure dlgReplaceTextReplace(Sender: TObject); Public/Published -
DoAutoSave procedure DoAutoSave(Suppress: integer = 1); Private -
EnableDisableMenus procedure EnableDisableMenus(IsTIUDocument: boolean); Private -
FormClose procedure FormClose(Sender: TObject; var Action: TCloseAction); Public/Published -
FormCreate procedure FormCreate(Sender: TObject); Public/Published Form events ------------------------------------------------------------------------------
FormDestroy procedure FormDestroy(Sender: TObject); Public/Published -
GetDrawers function GetDrawers: TfrmDrawers; Private -
GetTitleText function GetTitleText(AnIndex: Integer): string; Private
Supporting calls for writing notes 

 returns non-tabbed text for the title of a note given the ItemIndex in lstNotes
InsertAddendum procedure InsertAddendum; Private Sets up fields of pnlWrite to write an addendum for the selected note
InsertNewNote procedure InsertNewNote(IsIDChild: boolean; AnIDParent: integer); Private
Create, edit & save notes 

 creates the editing context for a new progress note & inserts stub into top of view list
LacksRequiredForCreate function LacksRequiredForCreate: Boolean; Private Determines if the fields required to create the note are present
LoadForEdit procedure LoadForEdit; Private Retrieves an existing note and places the data in the fields of pnlWrite
LoadSurgeryCases procedure LoadSurgeryCases; Private -
lstNotesClick procedure lstNotesClick(Sender: TObject); Public/Published Loads the text for the selected note or displays the editing panel for the selected note
memNewNoteChange procedure memNewNoteChange(Sender: TObject); Public/Published -
memNewNoteKeyDown procedure memNewNoteKeyDown(Sender: TObject; var Key: Word; Shift: TShiftState); Public/Published -
mnuActAddendClick procedure mnuActAddendClick(Sender: TObject); Public/Published Make an addendum to an existing note
mnuActChangeClick procedure mnuActChangeClick(Sender: TObject); Public/Published Right panel (editor) events --------------------------------------------------------------
mnuActDeleteClick procedure mnuActDeleteClick(Sender: TObject); Public/Published Delete the selected progress note & remove from the Encounter object if necessary
mnuActEditClick procedure mnuActEditClick(Sender: TObject); Public/Published Load the selected progress note for editing
mnuActIdentifyAddlSignersClick procedure mnuActIdentifyAddlSignersClick(Sender: TObject); Public/Published -
mnuActLoadBoilerClick procedure mnuActLoadBoilerClick(Sender: TObject); Public/Published -
mnuActNewClick procedure mnuActNewClick(Sender: TObject); Public/Published Switches to current new note or creates a new note if none is being edited already
mnuActSaveClick procedure mnuActSaveClick(Sender: TObject); Public/Published Saves the note that is currently being edited
mnuActSignClick procedure mnuActSignClick(Sender: TObject); Public/Published Sign the currently selected note, save first if necessary
mnuActSignListClick procedure mnuActSignListClick(Sender: TObject); Public/Published Add the note to the Encounter object, see mnuActSignClick - copied
mnuChartTabClick procedure mnuChartTabClick(Sender: TObject); Public/Published Reroute to Chart Tab menu of the parent form: frmFrame
mnuEditDialgFieldsClick procedure mnuEditDialgFieldsClick(Sender: TObject); Public/Published -
mnuEditSharedTemplatesClick procedure mnuEditSharedTemplatesClick(Sender: TObject); Public/Published -
mnuEditTemplatesClick procedure mnuEditTemplatesClick(Sender: TObject); Public/Published -
mnuIconLegendClick procedure mnuIconLegendClick(Sender: TObject); Public/Published -
mnuNewSharedTemplateClick procedure mnuNewSharedTemplateClick(Sender: TObject); Public/Published -
mnuNewTemplateClick procedure mnuNewTemplateClick(Sender: TObject); Public/Published -
mnuOptionsClick procedure mnuOptionsClick(Sender: TObject); Public/Published -
mnuViewClick procedure mnuViewClick(Sender: TObject); Public/Published
Changes the list of notes available for viewing 
AuthCtxt: TAuthorContext;
DateRange: TNoteDateRange;
mnuViewDetailClick procedure mnuViewDetailClick(Sender: TObject); Public/Published -
mnuViewInformationClick procedure mnuViewInformationClick(Sender: TObject); Public/Published -
mnuViewReturntoDefaultClick procedure mnuViewReturntoDefaultClick(Sender: TObject); Public/Published -
mnuViewSaveAsDefaultClick procedure mnuViewSaveAsDefaultClick(Sender: TObject); Public/Published -
pnlFieldsResize procedure pnlFieldsResize(Sender: TObject); Public/Published Center the reference date on the panel
pnlRightResize procedure pnlRightResize(Sender: TObject); Public/Published MemSurgery (TRichEdit) doesn't repaint appropriately unless it's parent panel is refreshed
pnlWriteResize procedure pnlWriteResize(Sender: TObject); Public/Published -
popNoteListCollapseAllClick procedure popNoteListCollapseAllClick(Sender: TObject); Public/Published -
popNoteListCollapseSelectedClick procedure popNoteListCollapseSelectedClick(Sender: TObject); Public/Published -
popNoteListExpandAllClick procedure popNoteListExpandAllClick(Sender: TObject); Public/Published -
popNoteListExpandSelectedClick procedure popNoteListExpandSelectedClick(Sender: TObject); Public/Published -
popNoteListPopup procedure popNoteListPopup(Sender: TObject); Public/Published -
popNoteMemoAddlSignClick procedure popNoteMemoAddlSignClick(Sender: TObject); Public/Published -
popNoteMemoCopyClick procedure popNoteMemoCopyClick(Sender: TObject); Public/Published -
popNoteMemoCutClick procedure popNoteMemoCutClick(Sender: TObject); Public/Published -
popNoteMemoFindClick procedure popNoteMemoFindClick(Sender: TObject); Public/Published -
popNoteMemoGrammarClick procedure popNoteMemoGrammarClick(Sender: TObject); Public/Published -
popNoteMemoInsTemplateClick procedure popNoteMemoInsTemplateClick(Sender: TObject); Public/Published -
popNoteMemoPasteClick procedure popNoteMemoPasteClick(Sender: TObject); Public/Published -
popNoteMemoPopup procedure popNoteMemoPopup(Sender: TObject); Public/Published -
popNoteMemoPreviewClick procedure popNoteMemoPreviewClick(Sender: TObject); Public/Published -
popNoteMemoReformatClick procedure popNoteMemoReformatClick(Sender: TObject); Public/Published -
popNoteMemoReplaceClick procedure popNoteMemoReplaceClick(Sender: TObject); Public/Published -
popNoteMemoSaveContinueClick procedure popNoteMemoSaveContinueClick(Sender: TObject); Public/Published -
popNoteMemoSpellClick procedure popNoteMemoSpellClick(Sender: TObject); Public/Published -
popNoteMemoTemplateClick procedure popNoteMemoTemplateClick(Sender: TObject); Public/Published -
ProcessNotifications procedure ProcessNotifications; Private
TmpNode: TTreeNode;
AnObject: PCaseTreeObject;
RemovePCEFromChanges procedure RemovePCEFromChanges(IEN: Int64; AVisitStr: string = ''); Private -
RequestPrint procedure RequestPrint; override; Public -
SaveCurrentNote procedure SaveCurrentNote(var Saved: Boolean); Private Called whenever a note should be saved - uses IEN to call appropriate save logic
SaveEditedNote procedure SaveEditedNote(var Saved: Boolean); Private Validates fields and sends the updated note to the server
SaveSignItem procedure SaveSignItem(const ItemID, ESCode: string); Public Saves and optionally signs a progress note or addendum
SetEditingIndex procedure SetEditingIndex(const Value: Integer); Private -
SetFontSize procedure SetFontSize(NewFontSize: Integer); override; Public Adjusts the font size of any controls that don't have ParentFont = True
SetSubjectVisible procedure SetSubjectVisible(ShouldShow: Boolean); Private Hide/show subject & resize panel accordingly - leave 6 pixel margin above memNewNote
SetSurgTreeLabel function SetSurgTreeLabel(AContext: TSurgCaseContext): string; Private -
SetViewContext procedure SetViewContext(AContext: TSurgCaseContext); Private -
ShowPCEButtons procedure ShowPCEButtons(Editing: boolean); Private -
ShowPCEControls procedure ShowPCEControls(ShouldShow: Boolean); Private -
sptHorzCanResize procedure sptHorzCanResize(Sender: TObject; var NewSize: Integer; var Accept: Boolean); Public/Published -
StartNewEdit function StartNewEdit(NewNoteType: integer): Boolean; Private
Action menu events ----------------------------------------------------------------------- 

 if currently editing a note, returns TRUE if the user wants to start a new one
timAutoSaveTimer procedure timAutoSaveTimer(Sender: TObject); Public/Published -
tvSurgeryChange procedure tvSurgeryChange(Sender: TObject; Node: TTreeNode); Public/Published
MsgString, HasImages: string;
ShowReport: boolean;
tvSurgeryClick procedure tvSurgeryClick(Sender: TObject); Public/Published -
tvSurgeryCollapsed procedure tvSurgeryCollapsed(Sender: TObject; Node: TTreeNode); Public/Published -
tvSurgeryExpanded procedure tvSurgeryExpanded(Sender: TObject; Node: TTreeNode); Public/Published -
UpdateTreeView procedure UpdateTreeView(DocList: TStringList; Tree: TORTreeView); Private -
VerifyNoteTitle function VerifyNoteTitle: Boolean; Private -
ViewInfo procedure ViewInfo(Sender: TObject); Public/Published -

Referenced By (3)

Module (line) Referrer Type
fFrame (3410) - Read
fSurgery (265) frmSurgery Read
fSurgery (2697) - Read