1 | //kt -- Modified with SourceScanner on 8/29/2007
|
---|
2 | unit uOrPtf; //PRF
|
---|
3 |
|
---|
4 | interface
|
---|
5 |
|
---|
6 | uses SysUtils, Windows, Classes, Forms, ORFn, ORNet, uCore;
|
---|
7 |
|
---|
8 | Type
|
---|
9 | TPatientFlag = Class(TObject)
|
---|
10 | private
|
---|
11 | FFlagID: string;
|
---|
12 | FName: string;
|
---|
13 | FNarr: TStringList;
|
---|
14 | FFlagIndex: integer;
|
---|
15 | public
|
---|
16 | property FlagID: string read FFlagID write FFlagID;
|
---|
17 | property Name: string read FName write FName;
|
---|
18 | property Narr: TStringList read FNarr write FNarr;
|
---|
19 | property FlagIndex: integer read FFlagIndex write FFlagIndex;
|
---|
20 | constructor Create;
|
---|
21 | procedure Clearup;
|
---|
22 | end;
|
---|
23 |
|
---|
24 | procedure HasActiveFlg(var FlagList: TStringList; var HasFlag: boolean; const PTDFN: string);
|
---|
25 | function TriggerPRFPopUp(PTDFN: String): boolean;
|
---|
26 | procedure GetActiveFlg(FlagInfo: TStrings; const PTDFN, FlagRecordID: string);
|
---|
27 | procedure ClearFlag;
|
---|
28 |
|
---|
29 | implementation
|
---|
30 |
|
---|
31 | procedure HasActiveFlg(var FlagList: TStringList; var HasFlag: boolean; const PTDFN: string);
|
---|
32 | begin
|
---|
33 | FlagList.Clear;
|
---|
34 | HasFlag := False;
|
---|
35 | CallV('ORPRF HASFLG',[PTDFN]);
|
---|
36 | if RPCBrokerV.Results.Count > 0 then
|
---|
37 | begin
|
---|
38 | FlagList.Assign(RPCBrokerV.Results);
|
---|
39 | HasFlag := True;
|
---|
40 | end;
|
---|
41 | end;
|
---|
42 |
|
---|
43 | function TriggerPRFPopUp(PTDFN: String): boolean;
|
---|
44 | begin
|
---|
45 | CallV('ORPRF TRIGGER POPUP',[PTDFN]);
|
---|
46 | Result := RPCBrokerV.Results[0] = '1';
|
---|
47 | RPCBrokerV.Results.Delete(0);
|
---|
48 | end;
|
---|
49 |
|
---|
50 | procedure TPatientFlag.Clearup;
|
---|
51 | begin
|
---|
52 | FFlagID := '0';
|
---|
53 | FName := '';
|
---|
54 | FNarr.Clear;
|
---|
55 | FFlagIndex := -1;
|
---|
56 | end;
|
---|
57 |
|
---|
58 | constructor TPatientFlag.Create;
|
---|
59 | begin
|
---|
60 | FFlagID := '0';
|
---|
61 | FName := '';
|
---|
62 | FNarr := TStringList.Create;
|
---|
63 | FFlagIndex := -1;
|
---|
64 | end;
|
---|
65 |
|
---|
66 | procedure GetActiveFlg(FlagInfo: TStrings; const PTDFN, FlagRecordID: string);
|
---|
67 | begin
|
---|
68 | CallV('ORPRF GETFLG', [PTDFN,FlagRecordID]);
|
---|
69 | if RPCBrokerV.Results.Count > 0 then
|
---|
70 | FlagInfo.Assign(RPCBrokerV.Results);
|
---|
71 | end;
|
---|
72 |
|
---|
73 | procedure ClearFlag;
|
---|
74 | begin
|
---|
75 | sCallV('ORPRF CLEAR',[nil]);
|
---|
76 | end;
|
---|
77 |
|
---|
78 | end.
|
---|