Home   Package List   Routine Alphabetical List   Global Alphabetical List   FileMan Files List   FileMan Sub-Files List   Package Component Lists   Package-Namespace Mapping  
Routine: DGFLICN

DGFLICN.m

Go to the documentation of this file.
DGFLICN ;ALB/CKN - RPC - DG FULL ICN SHOW/UPDATE; 11/17/00 12:12pm ; 11/24/17 6:07pm
 ;;5.3;Registration;**950**;Aug 13, 1993;Build 4
 ;
 ;**950 - Story 625205 (ckn)
 ;  This routine will support DG FULL ICN SHOW/UPDATE RPC calls
 Q
EN(RETURN,DGDATA) ;
 ;
 N RPCPAR,VFULLICN,VICN,VCHKSUM,DFN,MPIFICN,MPIICN,MPICHKSM,MPINODE
 S RPCPAR=$P(DGDATA,"^"),DFN=$P(DGDATA,"^",3),MPIFICN=$P(DGDATA,"^",4)
 S MPIICN=$P(MPIFICN,"V"),MPICHKSM=$P(MPIFICN,"V",2)
 S MPINODE=$G(^DPT(DFN,"MPI")),VICN=$P(MPINODE,"^"),VCHKSUM=$P(MPINODE,"^",2)
 S VFULLICN=$P(MPINODE,"^",10)
 I RPCPAR="S" S RETURN=VFULLICN_"^"_VICN_"^"_VCHKSUM Q  ;Only SHOW
 ;If input parameter is for Update
 I RPCPAR="U" D  Q
 .N DGFDA,DGERR
 .S DGFDA(2,DFN_",",991.1)=MPIFICN
 .S DGFDA(2,DFN_",",991.01)=MPIICN
 .S DGFDA(2,DFN_",",991.02)=MPICHKSM
 .D FILE^DIE("","DGFDA","DGERR")
 .I $D(DGERR) S RETURN="-1^Error filing data into Patient file - "_$G(DGERR("DIERR",1,"TEXT",1)) Q
 .S MPINODE=$G(^DPT(DFN,"MPI")),VICN=$P(MPINODE,"^"),VCHKSUM=$P(MPINODE,"^",2)
 .S VFULLICN=$P(MPINODE,"^",10)
 .S RETURN=VFULLICN_"^"_VICN_"^"_VCHKSUM
 Q