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

RTCL.m

Go to the documentation of this file.
  1. RTCL ; GENERATED FROM 'RT MISSING' PRINT TEMPLATE (#482) ; 07/15/96 ; (FILE 190.2, MARGIN=132)
  1. G BEGIN
  1. N W !
  1. T W:$X ! I '$D(DIOT(2)),DN,$D(IOSL),$S('$D(DIWF):1,$P(DIWF,"B",2):$P(DIWF,"B",2),1:1)+$Y'<IOSL,$D(^UTILITY($J,1))#2,^(1)?1U1P1E.E X ^(1)
  1. S DISTP=DISTP+1,DILCT=DILCT+1 D:'(DISTP#100) CSTP^DIO2
  1. Q
  1. DT I $G(DUZ("LANG"))>1,Y W $$OUT^DIALOGU(Y,"DD") Q
  1. I Y W $P("JAN^FEB^MAR^APR^MAY^JUN^JUL^AUG^SEP^OCT^NOV^DEC",U,$E(Y,4,5))_" " W:Y#100 $J(Y#100\1,2)_"," W Y\10000+1700 W:Y#1 " "_$E(Y_0,9,10)_":"_$E(Y_"000",11,12) Q
  1. W Y Q
  1. M D @DIXX
  1. Q
  1. BEGIN ;
  1. S:'$D(DN) DN=1 S DISTP=$G(DISTP),DILCT=$G(DILCT)
  1. I $D(DXS)<9 F X=0:0 S X=$O(^DIPT(482,"DXS",X)) Q:'X S Y=$O(^(X,"")) F X=X:0 Q:Y="" S DXS(X,Y)=^(Y),Y=$O(^(Y))
  1. S X=$G(^RTV(190.2,D0,0)) D N:$X>0 Q:'DN W ?0 S Y=$P(X,U,1) S C=$P(^DD(190.2,.01,0),U,2) D Y^DIQ:Y S C="," W $E(Y,1,20)
  1. S I(100)="^RT(",J(100)=190 S I(0,0)=D0 S DIP(1)=$S($D(^RTV(190.2,D0,0)):^(0),1:"") S X=$P(DIP(1),U,1),X=X S D(0)=+X S D0=D(0) I D0>0 D A1
  1. G A1R
  1. A1 ;
  1. S I(200)="^DPT(",J(200)=2 S I(100,0)=D0 S DIP(101)=$S($D(^RT(D0,0)):^(0),1:"") S X=$P(DIP(101),U,9),X=X S D(0)=+X S D0=D(0) I D0>0 D A2
  1. G A2R
  1. A2 ;
  1. X DXS(1,9.4) S X=$E(DIP(209),DIP(210),X) S Y=X,X=DIP(208),X=X_Y K DIP K:DN Y W X
  1. Q
  1. A2R ;
  1. K J(200),I(200) S:$D(I(100,0)) D0=I(100,0)
  1. S I(200)="^DIC(195.2,",J(200)=195.2 S I(100,0)=D0 S DIP(101)=$S($D(^RT(D0,0)):^(0),1:"") S X=$P(DIP(101),U,3),X=X S D(0)=+X S D0=D(0) I D0>0 D B2
  1. G B2R
  1. B2 ;
  1. S X=$G(^DIC(195.2,D0,0)) D N:$X>39 Q:'DN W ?39,$E($P(X,U,2),1,3)
  1. Q
  1. B2R ;
  1. K J(200),I(200) S:$D(I(100,0)) D0=I(100,0)
  1. S X=$G(^RT(D0,0)) S Y=$P(X,U,7) W:Y]"" $J(Y,3,0)
  1. Q
  1. A1R ;
  1. K J(100),I(100) S:$D(I(0,0)) D0=I(0,0)
  1. S X=$G(^RTV(190.2,D0,0)) D N:$X>51 Q:'DN W ?51 S Y=$P(X,U,4) W:Y]"" $S($D(DXS(3,Y)):DXS(3,Y),1:Y)
  1. S DIXX(1)="B1",I(0,0)=D0 X DXS(2,9)
  1. G B1R
  1. B1 ;
  1. I $D(DSC(190.3)) X DSC(190.3) E Q
  1. W:$X>63 ! S I(100)="^RTV(190.3,",J(100)=190.3
  1. S X=$G(^RTV(190.3,D0,0)) D N:$X>64 Q:'DN W ?64 S Y=$P(X,U,5) S C=$P(^DD(190.3,5,0),U,2) D Y^DIQ:Y S C="," W $E(Y,1,20)
  1. D N:$X>89 Q:'DN W ?89 S Y=$P(X,U,6) D DT
  1. D N:$X>114 Q:'DN W ?114 S Y=$P(X,U,15) W:Y]"" $S($D(DXS(4,Y)):DXS(4,Y),1:Y)
  1. Q
  1. B1R ;
  1. K J(100),I(100) S:$D(I(0,0)) D0=I(0,0)
  1. D T Q:'DN D N D N:$X>0 Q:'DN W ?0 W "Entered as Missing : "
  1. S X=$G(^RTV(190.2,D0,0)) S Y=$P(X,U,2) D DT
  1. D N:$X>49 Q:'DN W ?49 W "Entered By: "
  1. S Y=$P(X,U,3) S Y=$S(Y="":Y,$D(^VA(200,Y,0))#2:$P(^(0),U,1),1:Y) W $E(Y,1,35)
  1. D T Q:'DN D N D N:$X>0 Q:'DN W ?0 W "Supervisor Comments: "
  1. S I(1)=1,J(1)=190.21 F D1=0:0 Q:$O(^RTV(190.2,D0,1,D1))'>0 S D1=$O(^(D1)) D:$X>23 T Q:'DN D C1
  1. G C1R
  1. C1 ;
  1. S X=$G(^RTV(190.2,D0,1,D1,0)) S DIWL=25,DIWR=130 D ^DIWP
  1. Q
  1. C1R ;
  1. D A^DIWW
  1. D N:$X>0 Q:'DN W ?0 S X="-",DIP(1)=X,DIP(2)=X,X=$S($D(IOM):IOM,1:80) S X=X,X1=DIP(1) S %=X1 X:%]"" "F X=X:0 S %=%_X1 Q:$L(%)>X" S X=$E(%,1,X) K DIP K:DN Y W X
  1. D N:$X>0 Q:'DN W ?0 W "[The following fields will only contain information if the record was found by a user who is 'not' a file room supervisor.]"
  1. D T Q:'DN D N D N:$X>0 Q:'DN W ?0 W "Entered as Found : "
  1. S X=$G(^RTV(190.2,D0,0)) S Y=$P(X,U,6) D DT
  1. D N:$X>49 Q:'DN W ?49 W "Entered By: "
  1. S Y=$P(X,U,8) S Y=$S(Y="":Y,$D(^VA(200,Y,0))#2:$P(^(0),U,1),1:Y) W $E(Y,1,35)
  1. D N:$X>89 Q:'DN W ?89 W "Where it was found: "
  1. S Y=$P(X,U,5) S C=$P(^DD(190.2,5,0),U,2) D Y^DIQ:Y S C="," W $E(Y,1,30)
  1. D T Q:'DN D N D N:$X>0 Q:'DN W ?0 W "User Comments : "
  1. S I(1)=2,J(1)=190.22 F D1=0:0 Q:$O(^RTV(190.2,D0,2,D1))'>0 S D1=$O(^(D1)) D:$X>23 T Q:'DN D D1
  1. G D1R
  1. D1 ;
  1. S X=$G(^RTV(190.2,D0,2,D1,0)) S DIWL=25,DIWR=130 D ^DIWP
  1. Q
  1. D1R ;
  1. D A^DIWW
  1. D N:$X>0 Q:'DN W ?0 S X="=",DIP(1)=X,DIP(2)=X,X=$S($D(IOM):IOM,1:80) S X=X,X1=DIP(1) S %=X1 X:%]"" "F X=X:0 S %=%_X1 Q:$L(%)>X" S X=$E(%,1,X) K DIP K:DN Y W X
  1. D T Q:'DN D N W ?0 W ""
  1. K Y K DIWF
  1. Q
  1. W !,?0,"NAME",?39,"TYPE",?51,"STATUS",?64,"BORROWER HISTORY",?89,"CHARGED",?114,"BARCODED?"
  1. W !,"------------------------------------------------------------------------------------------------------------------------------------",!!