[613] | 1 | MPIFPST ;CMC/SF-MPI VISTA build post-init ;DEC 12, 1998
|
---|
| 2 | ;;1.0; MASTER PATIENT INDEX VISTA ;;30 Apr 99
|
---|
| 3 | ;
|
---|
| 4 | EN ;
|
---|
| 5 | D MAIL
|
---|
| 6 | D MAIL2
|
---|
| 7 | D HL7SITE
|
---|
| 8 | D CHECKMPI
|
---|
| 9 | D REMOVE
|
---|
| 10 | Q
|
---|
| 11 | REMOVE ;
|
---|
| 12 | S $P(^RGSITE(991.8,1,1),"^",2)=""
|
---|
| 13 | S DIK="^RGSITE(991.8,",DA=36,DA(1)=991.8
|
---|
| 14 | D ^DIK
|
---|
| 15 | K DIK,DA
|
---|
| 16 | Q
|
---|
| 17 | ;
|
---|
| 18 | CHECKMPI ; checking to see if MPI Institition is defined
|
---|
| 19 | N DIC,DA,DIE,DR,X,Y
|
---|
| 20 | S DIC="^DIC(4,",DIC(0)="XZ",X="MPI"
|
---|
| 21 | D ^DIC
|
---|
| 22 | I +Y<0 D BMES^XPDUTL("Missing MPI in Institution file, need to update before proceeding.")
|
---|
| 23 | Q
|
---|
| 24 | MAIL2 ;add mail group to 991.8
|
---|
| 25 | N DIC,GROUP,DIC,DA,DIE,DR,X,Y
|
---|
| 26 | S DIC="^XMB(3.8,",DIC(0)="XQZ",X="MPIF CMOR REQUEST"
|
---|
| 27 | D ^DIC
|
---|
| 28 | Q:+Y<0
|
---|
| 29 | S GROUP=+Y
|
---|
| 30 | S DA=1,DIE="^RGSITE(991.8,",DR=".03///^S X=GROUP" D ^DIE
|
---|
| 31 | D BMES^XPDUTL("Adding MPIF CMOR REQUEST mailgroup to file 991.8")
|
---|
| 32 | Q
|
---|
| 33 | ;add mail group to exception file
|
---|
| 34 | MAIL ;
|
---|
| 35 | N DIC,GROUP,DIC,DA,DIE,X,Y,DR,ENT
|
---|
| 36 | S DIC="^XMB(3.8,",DIC(0)="XQZ",X="MPIF EXCEPTIONS"
|
---|
| 37 | D ^DIC
|
---|
| 38 | Q:+Y<0
|
---|
| 39 | S GROUP=+Y
|
---|
| 40 | F ENT=200:1:208,210:1:212,220:1:222,224 D
|
---|
| 41 | .S DIC="^RGHL7(991.11,",DIC(0)="XQZ",X=ENT
|
---|
| 42 | .D ^DIC
|
---|
| 43 | .Q:+Y<0
|
---|
| 44 | .S DA=+Y,DIE="^RGHL7(991.11,",DR="6///^S X=GROUP"
|
---|
| 45 | .D ^DIE
|
---|
| 46 | Q
|
---|
| 47 | ;
|
---|
| 48 | HL7SITE ;updating Facility in the MPIF-Startup HL7 Application Parameter file
|
---|
| 49 | N SITE,DIE,X,Y,DR,ENT,DIC,DA,I
|
---|
| 50 | S SITE=$$SITE^VASITE,SITE=$P(SITE,"^",3),SITE=SITE\1
|
---|
| 51 | ; ^ SITE is Station Number of site doing install
|
---|
| 52 | F I="MPIF-STARTUP","MPIF CMOR RSLT","MPIF CMOR COMP","MPIF A29 SERVER","MPIF A30 SERVER","MPIF MPI","MPIF LOC/MIS" D
|
---|
| 53 | . S DIC="^HL(771,",DIC(0)="XQZ",X=I
|
---|
| 54 | . D ^DIC
|
---|
| 55 | . Q:+Y<0
|
---|
| 56 | . S DA=+Y
|
---|
| 57 | . S DIE="^HL(771,",DR="3///^S X=SITE"
|
---|
| 58 | . D ^DIE
|
---|
| 59 | Q
|
---|
| 60 | ;
|
---|