DGPFPARM ;ALB/RPM - PRF PARAMETER FILE EDIT ; 5/5/05 12:27pm
;;5.3;Registration;**425,554**;Aug 13, 1993
;
Q ;no direct entry
;
EN ;
N DA,DD,DO,DIC,DIE,DINUM,DR,X,Y
;
W !!,"Patient Record Flag Parameter Enter/Edit"
I '$D(^DGPF(26.18,1,0)) D
.W !,"You do not have an entry in your parameter file!!"
.W !,"Creating a new entry in the PRF PARAMETER (#26.18) file... ",!
.S DIC="^DGPF(26.18,",DIC(0)="",X=1,DINUM=1
.K DD,DO D FILE^DICN W " done."
.K %,DA,DIC,DIE,X,Y
;
S DIE="^DGPF(26.18,",DA=1,DR="2;3" D ^DIE
K DIE,DR,DA
Q
;
ON() ;Used to determine if the PRF software is 'active'.
;
; Input: None
;
;Output:
; Function Value - 1 = 'Active', 0 = 'Not Active'
;
; - init variables
N DGACT,RESULT
S RESULT=0
;
;- get software activation date from PRF PARAMETERS (#26.18) file
S DGACT=+$P($G(^DGPF(26.18,1,0)),U,2)
;
; - check if activation is past current date
D
.Q:('DGACT)!(DT<DGACT)
.S RESULT=1
;
Q RESULT
;
ORUON() ;Used to determine if ORU~R01 HL7 interface is 'enabled'.
;
;This function verifies that the PRF software is active and then
;returns the state of the Unsolicited Observation Update HL7 inteface
;in the PRF PARAMETERS (#26.18) file.
;
; Input:
; none
;
; Output:
; Function value - 1 if interface is enabled, 0 if interface is
; disabled
;
Q:'$$ON() 0
Q +$P($G(^DGPF(26.18,1,0)),U,3)
;
QRYON() ;Used to determine if QRY~R02 HL7 interface is 'enabled'.
;
;This function verifies that the PRF software is active and then
;returns the state of the QRY HL7 inteface in the PRF PARAMETERS
;(#26.18) file.
;
; Input:
; none
;
; Output:
; Function value - 0 if interface is disabled, 1 if interface is
; enabled in 'direct' mode, 2 if interface is
; enabled in 'deferred' mode.
;
Q:'$$ON() 0
Q +$P($G(^DGPF(26.18,1,0)),U,4)
;
P2ON() ;Used to determine if the PRF Phase 2 software is 'active'.
;
; Supported References:
; DBIA #4440 KERNEL SYSTEM PARAMETERS (PROD^XUPROD())
;
; Input: None
;
; Output:
; Function Value - 1 = 'Active', 0 = 'Not Active'
;
N DGACT ;activation date
N DGRESULT ;function value
;
S DGRESULT=0
;
;- get software activation date from PRF PARAMETERS (#26.18) file
S DGACT=+$P($G(^DGPF(26.18,1,0)),U,7)
;
;- check if activation is past current date in production
I $$PROD^XUPROD() D ;production account
. Q:('DGACT)!(DT<DGACT)
. S DGRESULT=1
E S DGRESULT=1 ;test account: always 'active'
;
Q DGRESULT
--- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HDGPFPARM 2625 printed Dec 13, 2024@02:48:31 Page 2
DGPFPARM ;ALB/RPM - PRF PARAMETER FILE EDIT ; 5/5/05 12:27pm
+1 ;;5.3;Registration;**425,554**;Aug 13, 1993
+2 ;
+3 ;no direct entry
QUIT
+4 ;
EN ;
+1 NEW DA,DD,DO,DIC,DIE,DINUM,DR,X,Y
+2 ;
+3 WRITE !!,"Patient Record Flag Parameter Enter/Edit"
+4 IF '$DATA(^DGPF(26.18,1,0))
Begin DoDot:1
+5 WRITE !,"You do not have an entry in your parameter file!!"
+6 WRITE !,"Creating a new entry in the PRF PARAMETER (#26.18) file... ",!
+7 SET DIC="^DGPF(26.18,"
SET DIC(0)=""
SET X=1
SET DINUM=1
+8 KILL DD,DO
DO FILE^DICN
WRITE " done."
+9 KILL %,DA,DIC,DIE,X,Y
End DoDot:1
+10 ;
+11 SET DIE="^DGPF(26.18,"
SET DA=1
SET DR="2;3"
DO ^DIE
+12 KILL DIE,DR,DA
+13 QUIT
+14 ;
ON() ;Used to determine if the PRF software is 'active'.
+1 ;
+2 ; Input: None
+3 ;
+4 ;Output:
+5 ; Function Value - 1 = 'Active', 0 = 'Not Active'
+6 ;
+7 ; - init variables
+8 NEW DGACT,RESULT
+9 SET RESULT=0
+10 ;
+11 ;- get software activation date from PRF PARAMETERS (#26.18) file
+12 SET DGACT=+$PIECE($GET(^DGPF(26.18,1,0)),U,2)
+13 ;
+14 ; - check if activation is past current date
+15 Begin DoDot:1
+16 if ('DGACT)!(DT<DGACT)
QUIT
+17 SET RESULT=1
End DoDot:1
+18 ;
+19 QUIT RESULT
+20 ;
ORUON() ;Used to determine if ORU~R01 HL7 interface is 'enabled'.
+1 ;
+2 ;This function verifies that the PRF software is active and then
+3 ;returns the state of the Unsolicited Observation Update HL7 inteface
+4 ;in the PRF PARAMETERS (#26.18) file.
+5 ;
+6 ; Input:
+7 ; none
+8 ;
+9 ; Output:
+10 ; Function value - 1 if interface is enabled, 0 if interface is
+11 ; disabled
+12 ;
+13 if '$$ON()
QUIT 0
+14 QUIT +$PIECE($GET(^DGPF(26.18,1,0)),U,3)
+15 ;
QRYON() ;Used to determine if QRY~R02 HL7 interface is 'enabled'.
+1 ;
+2 ;This function verifies that the PRF software is active and then
+3 ;returns the state of the QRY HL7 inteface in the PRF PARAMETERS
+4 ;(#26.18) file.
+5 ;
+6 ; Input:
+7 ; none
+8 ;
+9 ; Output:
+10 ; Function value - 0 if interface is disabled, 1 if interface is
+11 ; enabled in 'direct' mode, 2 if interface is
+12 ; enabled in 'deferred' mode.
+13 ;
+14 if '$$ON()
QUIT 0
+15 QUIT +$PIECE($GET(^DGPF(26.18,1,0)),U,4)
+16 ;
P2ON() ;Used to determine if the PRF Phase 2 software is 'active'.
+1 ;
+2 ; Supported References:
+3 ; DBIA #4440 KERNEL SYSTEM PARAMETERS (PROD^XUPROD())
+4 ;
+5 ; Input: None
+6 ;
+7 ; Output:
+8 ; Function Value - 1 = 'Active', 0 = 'Not Active'
+9 ;
+10 ;activation date
NEW DGACT
+11 ;function value
NEW DGRESULT
+12 ;
+13 SET DGRESULT=0
+14 ;
+15 ;- get software activation date from PRF PARAMETERS (#26.18) file
+16 SET DGACT=+$PIECE($GET(^DGPF(26.18,1,0)),U,7)
+17 ;
+18 ;- check if activation is past current date in production
+19 ;production account
IF $$PROD^XUPROD()
Begin DoDot:1
+20 if ('DGACT)!(DT<DGACT)
QUIT
+21 SET DGRESULT=1
End DoDot:1
+22 ;test account: always 'active'
IF '$TEST
SET DGRESULT=1
+23 ;
+24 QUIT DGRESULT