source: FOIAVistA/tag/r/IFCAP-PRC-PRX--PRCA--PRCN/PRCPULAB.m@ 897

Last change on this file since 897 was 628, checked in by George Lilly, 15 years ago

initial load of FOIAVistA 6/30/08 version

File size: 2.0 KB
Line 
1PRCPULAB ;WISC/RGY-print barcode labels ;4.21.98
2 ;;5.1;IFCAP;;Oct 20, 2000
3 ;Per VHA Directive 10-93-142, this routine should not be modified.
4S W !!,"Do you want to (S)earch/sort inventory items before printing",!,"... or just (P)rint a range of inventory items ? P//" R X:DTIME S:'$T X="^" S:X="" X="P" G:X="^" Q
5 I "SP"'[X W $C(7),!!,"Enter an 'S' to search and print or 'P' to print a specific range of items",! G S
6 I X="S" D Q G EN^PRCTLAB
7 W ! S DIC="^PRCP(445,",DIC(0)="QEAM",PRCPPRIV=1 D ^DIC K PRCPPRIV G:Y<0 Q S PRCPIP=+Y
8STA R !,"Start with item #: ",X:DTIME G:"^"[$E(X) Q I X'?.N W !!,"Enter the item number for this inventory point that you want to start",!,"printing from.",! G STA
9 S PRCPSTA=X
10END R !," End with item #: ",X:DTIME G:"^"[$E(X) Q I X'?.N W !!,"Enter the item number for this inventory point that you want to end with.",! G END
11 S PRCPEND=X
12 I PRCPSTA=PRCPEND,'$D(^PRCP(445,PRCPIP,1,PRCPSTA,0)) W $C(7),!!,"There is not item # "_PRCPSTA_" defined for this inventory point.",! G STA
13 I PRCPSTA>PRCPEND W $C(7),!!,"The beginning item number is greater than the ending item number.",! G STA
14DEV ; select device
15 S %ZIS("A")="Select BAR CODE PRINTER: ",%ZIS("B")="",%ZIS="Q"
16 K IO("Q") D ^%ZIS K %ZIS G:POP Q
17 G:'$D(IO("Q")) DQ
18 ; queueing has been requested
19 S ZTRTN="DQ^PRCPULAB" F X="PRCPIP","PRCPSTA","PRCPEND","PRCT" S ZTSAVE(X)=""
20 S ZTDESC="Bar Code Label Print",ZTIO=ION D ^%ZTLOAD,HOME^%ZIS K PRCT
21Q K POP,PRCPSTA,PRCPEND,PRCPIP Q
22 ;
23DQ ;
24 G:$S('$D(PRCT):1,'$D(^PRCT(446.5,PRCT,0)):1,'$D(^PRCT(446.6,+$P(^(0),"^",6),0)):1,1:0) Q1 S PRCT=$P(^PRCT(446.5,PRCT,0),"^",6) F X=0:0 S X=$O(^PRCT(446.6,PRCT,1,X)) Q:'X W @^(X,0)
25 F PRCPSTA=PRCPSTA-1:0 S PRCPSTA=$O(^PRCP(445,PRCPIP,1,PRCPSTA)) Q:PRCPSTA>PRCPEND!'PRCPSTA D PRNT
26Q1 K PRCPSTA,PRCPEND,PRCPIP,PRCT Q
27PRNT ;
28 F X=0:0 S X=$O(^PRCT(446.6,PRCT,2,X)) Q:'X W @(^(X,0))
29 S X=$$DESCR^PRCPUX1(PRCPIP,PRCPSTA) S:X="" X="NO DESCRIPTION" W $E(X,1,30),!," ",!,"IE",PRCPIP," ",PRCPSTA
30 F X=0:0 S X=$O(^PRCT(446.6,PRCT,3,X)) Q:'X W @(^(X,0))
31 Q
Note: See TracBrowser for help on using the repository browser.