Ignore:
Timestamp:
Jul 7, 2010, 4:51:54 PM (14 years ago)
Author:
Kevin Toppenberg
Message:

Upgrading to version 27

File:
1 edited

Legend:

Unmodified
Added
Removed
  • cprs/trunk/CPRS-Chart/fNoteProps.pas

    r456 r830  
    66  Windows, Messages, SysUtils, Classes, Graphics, Controls, Forms, Dialogs,
    77  StdCtrls, ORDtTm, ORCtrls, ExtCtrls, rTIU, uConst, uTIU, ORFn, ORNet,
    8   ComCtrls, Buttons;
     8  ComCtrls, Buttons, fBase508Form, VA508AccessibilityManager;
    99
    1010type
     
    2828  end;
    2929
    30   TfrmNoteProperties = class(TForm)
     30  TfrmNoteProperties = class(TfrmBase508Form)
    3131    lblNewTitle: TLabel;
    3232    cboNewTitle: TORComboBox;
     
    9292    procedure lstRequestsChange(Sender: TObject);
    9393  private
     94    FIsNewNote : Boolean;     // Is set at the begining of the function: ExecuteNoteProperties
    9495    FCosignIEN: Int64;      // store cosigner that was passed in
    9596    FCosignName: string;    // store cosigner that was passed in
     
    141142{$R *.DFM}
    142143
    143 uses uCore, rCore, rConsults, uConsults, rSurgery, uAccessibleListBox, fRptBox;
     144uses uCore, rCore, rConsults, uConsults, rSurgery, fRptBox;
    144145
    145146{ Initial values in ANote
     
    212213begin
    213214  frmNoteProperties := TfrmNoteProperties.Create(Application);
     215  frmNoteProperties.FIsNewNote := ANote.IsNewNote;
    214216  uConsultsList := TStringList.Create;
    215217  try
     
    337339        FormatRequestList;
    338340      end ;
    339       TAccessibleListBox.WrapControl(cboNewTitle);
    340       try
    341         Result := ShowModal = idOK;                // display the form
    342       finally
    343         TAccessibleListBox.UnwrapControl(cboNewTitle);
    344       end;
     341      Result := ShowModal = idOK;                // display the form
    345342      if Result then with ANote do
    346343      begin
     
    399396                              PkgRef := IntToStr(PkgIEN) + ';' + PkgPtr;
    400397                            end
    401                           else if pnlPRF.Visible then //PRF
     398                          else if (pnlPRF.Visible) and (lvPRF.ItemIndex >= 0) then //PRF
    402399                            begin
    403400                              PRF_IEN := FPRFActions.GetPRF_IEN(lvPRF.ItemIndex);
    404401                              ActionIEN := FPRFActions.GetActionIEN(lvPRF.ItemIndex);
     402                            end
     403                          else
     404                            begin
     405                              PkgIEN := 0;
     406                              PkgPtr := '';
     407                              PkgRef := '';
    405408                            end;
    406409                        end;
     
    440443  if FDocType = TYP_ADDENDUM then
    441444  begin
    442     lblCosigner.Visible := AskCosignerForDocument(FAddend, cboAuthor.ItemIEN)
     445    lblCosigner.Visible := AskCosignerForDocument(FAddend, cboAuthor.ItemIEN, calNote.FMDateTime)
    443446  end else
    444447  begin
     
    498501    begin
    499502      lblConsult2.Caption := ALL_CONSULTS;
    500       lstRequests.Items.Assign(uConsultsList);
     503      FastAssign(uConsultsList, lstRequests.Items);
    501504    end;
    502505    lblConsult1.Visible := (cboNewTitle.ItemIndex > -1);
     
    696699          else if (pnlPRF.Visible) then
    697700          begin
    698             if (lvPRF.ItemIndex < 0) then
    699               ErrMsg := ErrMsg + TX_REQ_PRF_ACTION
    700             else if FPRFActions.SelActionHasNote(lvPRF.ItemIndex) then
     701            if (lvPRF.ItemIndex < 0) and (FIsNewNote) then
     702              ErrMsg := ErrMsg + TX_REQ_PRF_ACTION;
     703            if (lvPRF.ItemIndex >= 0) and (FPRFActions.SelActionHasNote(lvPRF.ItemIndex)) then
    701704              ErrMsg := ErrMsg + TX_REQ_PRF_NOTE;
    702705          end;
     
    869872begin
    870873  CallV('TIU GET PRF ACTIONS', [TitleIEN,DFN]);
    871   FPRFActionList.Assign(RPCBrokerV.Results);
     874  FastAssign(RPCBrokerV.Results, FPRFActionList);
    872875end;
    873876
Note: See TracChangeset for help on using the changeset viewer.