LRPRE ;SLC/FHS-REG PRE-INITS FOR VERSION 5.0 ;5/31/89 13:36 ; [ 09/05/91 1:36 PM ]
;;V~5.0~;LAB;;02/27/90 17:09
A ;
I $S('$D(DUZ):1,'$D(^DIC(3,+DUZ)):1,'$D(IO):1,1:0) G DUZ
I $S('$D(DUZ(0)):1,DUZ(0)'="@":1,1:0) G DUZ0
I DUZ(0)'="@" G DUZ0
;I $D(^DD(60,0,"VR")),+^DD(60,0,"VR")<4.08 W !,*7,"YOU MUST HAVE AT LEAST VERSION 4.08 BEFORE I CAN INIT THIS VERSION ",$P($T(+2),"~",2),! K DIFQ Q
K ^UTILITY("LRINIT") S VER=$P($T(+2),"~",2),U="^" S (^LR("VERSION"),^LAR("VERSION"),^LAM("VERSION"),^LAC("VERSION"),^LRD("VERSION"),^LRE("VERSION"),^LRT("VERSION"),^LAB("VERSION"),^LRO("VERSION"))=VER
S LRSITE=$S($D(^DD("SITE")):^("SITE"),1:"UNKNOWN") S %DT="R",X="NOW" D ^%DT S ^UTILITY("LRINIT",LRSITE,0)=Y_"^"_$H_"^START TIME"
S ^UTILITY("LRINIT",LRSITE,"VER",0)="NEW UCI NOT IN PACKAGE FILE"
S X="LAB SERVICE",DIC="^DIC(9.4,",DIC(0)="Z" D ^DIC I Y>0 S VER=$S($D(^DIC(9.4,+Y,22,0)):^(0),1:"NONE") I $D(^DIC(9.4,+Y,22,+$P(VER,U,3),0)) S ^UTILITY("LRINIT",LRSITE,"VER",0)=^(0)
B ;KILL UNNEEDED CROSS-REFERENCE DATA DICTIONARY
S DIK="^DD(68.02,9,1,",DA(2)="68.02",DA(1)=9 F DA=0:0 S DA=$O(@(DIK_DA_")")) Q:DA'>0 D ^DIK
K ^LAB(69.91) S ^LAB(69.91,0)="LR ROUTINE INTEGRITY CHECKER^69.91I^0^0"
C D ^LRAPKOPT S %DT="R",X="NOW" D ^%DT S ^UTILITY("LRINIT",LRSITE,1)=Y_U_$H_"^END LRAPKOPT"
K ^LRD(65,"B") F I=0:0 S I=$N(^LRD(65,I)) Q:I<1 S X=$P(^LRD(65,I,0),U,1) S ^LRD(65,"B",$E(X,1,30),I)="" I $L(X)>4 F X(1)=2:1:4 I '$E(X,X(1)) S ^LRD(65,"C",$E(X,X(1),$L(X)),I)="" Q
Q
DUZ W !!?10,"Please log in using access and verify codes",!!,*7 K DIFQ Q
DUZ0 W !!?10,"You do not have programmer access in your fileman access code",!!,*7 K DIFQ Q
LRPRE ;SLC/FHS-REG PRE-INITS FOR VERSION 5.0 ;5/31/89 13:36 ; [ 09/05/91 1:36 PM ]
+1 ;;V~5.0~;LAB;;02/27/90 17:09
A ;
+1 IF $SELECT('$DATA(DUZ):1,'$DATA(^DIC(3,+DUZ)):1,'$DATA(IO):1,1:0)
GOTO DUZ
+2 IF $SELECT('$DATA(DUZ(0)):1,DUZ(0)'="@":1,1:0)
GOTO DUZ0
+3 IF DUZ(0)'="@"
GOTO DUZ0
+4 ;I $D(^DD(60,0,"VR")),+^DD(60,0,"VR")<4.08 W !,*7,"YOU MUST HAVE AT LEAST VERSION 4.08 BEFORE I CAN INIT THIS VERSION ",$P($T(+2),"~",2),! K DIFQ Q
+5 KILL ^UTILITY("LRINIT")
SET VER=$PIECE($TEXT(+2),"~",2)
SET U="^"
SET (^LR("VERSION"),^LAR("VERSION"),^LAM("VERSION"),^LAC("VERSION"),^LRD("VERSION"),^LRE("VERSION"),^LRT("VERSION"),^LAB("VERSION"),^LRO("VERSION"))=VER
+6 SET LRSITE=$SELECT($DATA(^DD("SITE")):^("SITE"),1:"UNKNOWN")
SET %DT="R"
SET X="NOW"
DO ^%DT
SET ^UTILITY("LRINIT",LRSITE,0)=Y_"^"_$HOROLOG_"^START TIME"
+7 SET ^UTILITY("LRINIT",LRSITE,"VER",0)="NEW UCI NOT IN PACKAGE FILE"
+8 SET X="LAB SERVICE"
SET DIC="^DIC(9.4,"
SET DIC(0)="Z"
DO ^DIC
IF Y>0
SET VER=$SELECT($DATA(^DIC(9.4,+Y,22,0)):^(0),1:"NONE")
IF $DATA(^DIC(9.4,+Y,22,+$PIECE(VER,U,3),0))
SET ^UTILITY("LRINIT",LRSITE,"VER",0)=^(0)
B ;KILL UNNEEDED CROSS-REFERENCE DATA DICTIONARY
+1 SET DIK="^DD(68.02,9,1,"
SET DA(2)="68.02"
SET DA(1)=9
FOR DA=0:0
SET DA=$ORDER(@(DIK_DA_")"))
IF DA'>0
QUIT
DO ^DIK
+2 KILL ^LAB(69.91)
SET ^LAB(69.91,0)="LR ROUTINE INTEGRITY CHECKER^69.91I^0^0"
C DO ^LRAPKOPT
SET %DT="R"
SET X="NOW"
DO ^%DT
SET ^UTILITY("LRINIT",LRSITE,1)=Y_U_$HOROLOG_"^END LRAPKOPT"
+1 KILL ^LRD(65,"B")
FOR I=0:0