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

ABSPOSCH.m

Go to the documentation of this file.
ABSPOSCH ; IHS/FCS/DRS - Set up ABSP() ;      [ 05/09/2003  9:37 AM ]
 ;;1.0;PHARMACY POINT OF SALE;**1,4,6,9,11,15,16,17,19,20,21,29,37,40,42**;JUN 01, 2001;Build 38
 ;---
 ;Moved over subroutines from ABSPOSCC due to SAC size standards
 ;
CAIDNAME()         Q $P($G(^AUPNMCD(PINSDA,21)),U)
CAIDELDT() ;CAID ELIG BEGIN AND END DATES
 N D1,BEGDT,ENDDT
 S (BEGDT,ENDDT)=""
 S D1=$O(^AUPNMCD(PINSDA,11,"A"),-1)
 I D1 D
 . S BEGDT=$P(^AUPNMCD(PINSDA,11,D1,0),U,1)
 . S ENDDT=$P(^AUPNMCD(PINSDA,11,D1,0),U,2)
 Q BEGDT_U_ENDDT
CARENAME()         ;Q $P($G(^AUPNMCR(PINSDA,21)),U)
 N NAME,MDNAME
 S NAME=$P($G(^AUPNMCR(PINSDA,21)),U)     ;orig
 S MDNAME=""
 ;RLT 21
 ;S:MDIEN'="" MDNAME=$P($G(^AUPNMCR(PINSDA,11,MDIEN,0)),U,5)   ;MPD
 S:MDFLG&(MDIEN) MDNAME=$P($G(^AUPNMCR(PINSDA,11,MDIEN,0)),U,5)   ;MPD
 S:MDNAME'="" NAME=MDNAME
 Q NAME
 ;IHS/SD/lwj 11/25/02 get Medicaid DOB
CAIDDOB()          Q $P($G(^AUPNMCD(PINSDA,21)),U,2)  ;dob
CAREDOB() ;
 N DOB,MDDOB
 S DOB=$P($G(^AUPNMCR(PINSDA,21)),U,2)      ;orig
 S MDDOB=""
 ;RLT
 ;S:MDIEN'="" MDDOB=$P($G(^AUPNMCR(PINSDA,11,MDIEN,0)),U,9)    ;MPD
 S:MDFLG&(MDIEN) MDDOB=$P($G(^AUPNMCR(PINSDA,11,MDIEN,0)),U,9)      ;MPD
 S:MDDOB'="" DOB=MDDOB
 Q DOB
GETAINFO ;Address Info for 322,323,324 and 325 fields.
 ;
 N ABSPAREC
 S ABSPAREC=$G(^DPT(PATIEN,.11))
 Q:ABSPAREC=""
 ;
 S ABSP("Patient","Street Address")=$P(ABSPAREC,U)
 S ABSP("Patient","City")=$P(ABSPAREC,U,4)
 I $P(ABSPAREC,U,5)'="" D
 . S ABSP("Patient","State")=$P($G(^DIC(5,$P(ABSPAREC,U,5),0)),U,2)
 S ABSP("Patient","Zip")=$P(ABSPAREC,U,6)
 ;
 Q