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

BQIDCPM.m

Go to the documentation of this file.
BQIDCPM ;PRXM/HC/ALA-Predefined Panel Parameters ; 24 Oct 2005  6:21 PM
 ;;2.1;ICARE MANAGEMENT SYSTEM;;Feb 07, 2011
 ;
 Q
 ;
EN(DATA,PPIEN) ; EP -- BQI GET PREDEF PARAM LIST
 ;Description
 ;  Get the definition of a predefined panel
 ;Input
 ;  PPIEN - Internal entry number of a predefined panel
 ;Output
 ;  DATA - Global reference to store data
 ;
 NEW UID,II,HDR,NN,X
 S UID=$S($G(ZTSK):"Z"_ZTSK,1:$J)
 S DATA=$NA(^TMP("BQIDCPM",UID))
 K @DATA
 ;
 S II=0
 NEW $ESTACK,$ETRAP S $ETRAP="D ERR^BQIDCPM D UNWIND^%ZTER" ; SAC 2006 2.2.3.3.2
 ;
 S II=II+1
 S HDR="I00010PARAM_IEN^T00030PARAM_NAME^T00001PARAM_TYPE^T00030PARAM_UPPER^"
 S HDR=HDR_"T00030PARAM_LOWER^T00030PARAM_DEFAULT^T00001PARAM_REQ^"
 S HDR=HDR_"T00030PARAM_EXCLUSION^T00020PARAM_TABLE^T00250PARAM_CHOICES"
 S @DATA@(II)=HDR_$C(30)
 ;
 ;  Get the parameter definitions
 S NN=0
 F  S NN=$O(^BQI(90506,PPIEN,3,NN)) Q:'NN  D
 . NEW DA,IENS,PARNM,PARTY,PARUP,PARLO,PARDF,PARRQ,PAREX,PARTB,PARCH
 . S DA(1)=PPIEN,DA=NN,IENS=$$IENS^DILF(.DA)
 . S PARNM=$$GET1^DIQ(90506.03,IENS,.01,"E")
 . S PARTY=$$GET1^DIQ(90506.03,IENS,.02,"I")
 . S PARUP=$$GET1^DIQ(90506.03,IENS,.03,"E")
 . S PARLO=$$GET1^DIQ(90506.03,IENS,.04,"E")
 . S PARDF=$$GET1^DIQ(90506.03,IENS,.05,"E")
 . S PARRQ=$$GET1^DIQ(90506.03,IENS,.06,"I")
 . S PAREX=$$GET1^DIQ(90506.03,IENS,.07,"E")
 . S PARTB=$$GET1^DIQ(90506.03,IENS,.08,"E")
 . S PARCH=$$GET1^DIQ(90506.03,IENS,1,"E")
 . ;
 . S II=II+1
 . S @DATA@(II)=NN_"^"_PARNM_"^"_PARTY_"^"_PARUP_"^"_PARLO_"^"_PARDF_"^"_PARRQ_"^"_PAREX_"^"_PARTB
 . S @DATA@(II)=@DATA@(II)_"^"_PARCH_$C(30)
 ;
 S II=II+1,@DATA@(II)=$C(31)
 Q
 ;
ERR ;
 D ^%ZTER
 NEW Y,ERRDTM
 S Y=$$NOW^XLFDT() X ^DD("DD") S ERRDTM=Y
 S BMXSEC="Recording that an error occurred at "_ERRDTM
 I $D(II),$D(DATA) S II=II+1,@DATA@(II)=$C(31)
 Q