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

CIAVIP12.m

Go to the documentation of this file.
CIAVIP12 ;MSC/IND/PLS - EHR v1.1p12 Inits;31-Oct-2013 09:10;PLS
 ;;1.1;VUECENTRIC FRAMEWORK;;23-Oct-2006
 ;;Copyright 2000-2012, Medsphere Systems Corporation
 ;=================================================================
EC ;EP - Environment check
 Q
PRE ;EP - Preinit
 Q
POST ;EP - Postinit
 N VER,FDA,PID,IEN,X,TYPE
 D BMES^XPDUTL("Updating version numbers...")
 F VER=0:1 S X=$P($T(VER+VER),";;",2) Q:'$L(X)  D
 .S PID=$$PRGID^CIAVMCFG($P(X,";"))
 .S:PID FDA(19930.2,PID_",",2)=$P(X,";",2),FDA(19930.2,PID_",",7)=$P(X,";",3)
 D:$D(FDA) FILE^DIE(,"FDA")
 W !!!
 I $L($$GETLOGIN^CIAVUTIL),$$ASK^CIAU("Do you want to enable EHR logins","Y") D
 .D SDABORT^CIAVUTIL(,1),BMES^XPDUTL("Application logins have been enabled.")
 D UPDCHM
 Q
 ; Attach Event Protocols to Event Types
EVTPRTL(TYPE) ;
 N EVTNM,PRT,EVT,FDA
 S EVTNM="CIAV "_TYPE_" EVENT"
 S EVT=$$EVENTIEN^CIANBEVT(TYPE)
 Q:'EVT
 S PRT=$$FIND1^DIC(101,,,EVTNM)
 Q:'PRT
 S FDA(19941.21,EVT_",",7)=PRT
 D FILE^DIE(,"FDA")
 Q
 ;
UPDCHM ;EP-
 N CHM,PID
 F CHM=0:1 S X=$P($T(CHM+CHM),";;",2) Q:'$L(X)  D
 .S PID=$$PRGID^CIAVMCFG($P(X,";"))
 .D AECHM(PID,$P(X,";",2,99))
 W !!
 Q
 ;
AECHM(PID,VAL) ;EP-
 N LN,FN,IDX,TXT,ARY,CNT,IENS
 S FN=$P(VAL,";"),CNT=0
 S LN=0 F  S LN=$O(^CIAVOBJ(19930.2,PID,6,LN)) Q:'LN  D  Q:$G(IDX)
 .S TXT=^CIAVOBJ(19930.2,PID,6,LN,0)
 .S ARY(LN,0)=TXT,CNT=CNT+1
 .I $$UP^XLFSTR(TXT)[$$UP^XLFSTR($P(VAL,";")) S IDX=LN
 I $G(IDX) D
 .S ^CIAVOBJ(19930.2,PID,6,IDX,0)=VAL
 E  D
 .S ARY($S('CNT:1,1:CNT+1),0)=VAL
 .S IENS=PID_","
 .S FDA(19930.2,IENS,10)="ARY"
 .D FILE^DIE(,"FDA")
 Q
 ; Rename .01 field of BEH Measurement file
BEHMSR(X,Y) ;
 N IEN,FDA
 S IEN=$O(^BEHOVM(90460.01,"B",X,0))
 Q:'IEN
 S FDA(90460.01,IEN_",",.01)=Y
 D FILE^DIE(,"FDA")
 Q
VER ;;BEHRXGENERATORSERVICE.RXGENERATOR;1.0.0.89;DC1A781429272103FFCC12BDFE07901B
 ;;BEHORDERS.ORDERENTRY;27.1.1.6;6178D6BD5E8B29367674162FECC133B4
 ;;BEHCOMMUNITYINFO.COMMUNITYINFO;1.1.0.66;2E42243E2774644DB4DE745AB6B01288
 ;;BEHQOWIZARD.QOWIZARD;1.1.4.22;42F039651661E00C7D88197DD2E3B6F7
 ;;BEHCONTEXTADAPTER.CONTEXTADAPTER;4.2.3.3;EC9B75CC3ACF5CB9FEF99E9B8B47AB66
 ;;
CHM ;;BEHESIGREVIEW.REVIEW;BEHESigReview.chm;2012.11.9.190632;0357E3597B0074920A86631D9316FB26
 ;;BEHORDERS.ORDERENTRY;BEHOrders.chm;2013.5.23.184000;55E87EF9CC36B229BB4BF4697D04A8FD
 ;;BEHCOMMUNITYINFO.COMMUNITYINFO;BEHCommunityInfo.chm;2013.5.23.151900;776A2AB1F3EEFE215636516959041195
 ;;BEHRXGENERATORSERVICE.RXGENERATOR;BEHRxGenerator.chm;2013.6.3.183118;B2A71B05C395583F1765C1E6CA646908
 ;;BEHMEDS.MEDMANAGEMENT;BEHMeds.chm;2013.6.12.164500;2854EA979F3DAB986F14175D01A42C74