source: WorldVistAEHR/trunk/r/ENGINEERING-EN/ENWOME2.m@ 1169

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

initial load of WorldVistAEHR

File size: 1.3 KB
RevLine 
[613]1ENWOME2 ;(WASH ISC)/SAB-WORK ORDER MULTIPLE ENTRY, PRINT NEW WO ;1.6.96
2 ;;7.0;ENGINEERING;**35**;Aug 17, 1993
3 ; Input Variables
4 ; ENPRT("DEV") = selected output device
5 ; ENWODA = ien of master work order (File #6920)
6 ; ^TMP($J,equip ien) selected equipment array
7 ; = work order ien^work order number
8QUETSK ; queue task to print new work orders
9 S ZTRTN="DQ^ENWOME2",ZTDESC="Multiple Work Order Hardcopy Print"
10 S ZTDTH=$H,ZTIO=ENPRT("DEV")
11 S ZTSAVE("ENWODA")="",ZTSAVE("^TMP($J,")=""
12 D ^%ZTLOAD,HOME^%ZIS K ZTSK
13 Q
14DQ ; queued entry point
15 ; get software setting for barcodes
16 S ENBARCD=0
17 S ENI=$O(^ENG(6910.2,"B","PRINT BAR CODES ON W.O.",0))
18 I ENI,$P($G(^ENG(6920.2,ENI,0)),U,2)="Y" S ENBARCD=1
19 ; get software setting for long/short format wo
20 S ENI=$O(^ENG(6910.2,"B","AUTO PRINT NEW W.O.",0))
21 S ENPRT("AUTO")=$S(ENI:$P($G(^ENG(6910.2,ENI,0)),U,2),1:"")
22 ; print work orders in appropriate format
23 S DA=ENWODA N IOINHI,IOINLOW D ZIS^ENUTL
24 I ENPRT("AUTO")="S" D FDAT4^ENWOP3
25 I ENPRT("AUTO")'="S" D PRT1^ENWOD W @$G(IOF)
26 S ENI=0 F S ENI=$O(^TMP($J,ENI)) Q:'ENI S ENDA=$P($G(^(ENI)),U) D:ENDA
27 . S DA=ENDA N IOINHI,IOINLOW D ZIS^ENUTL
28 . I ENPRT("AUTO")="S" D FDAT4^ENWOP3
29 . I ENPRT("AUTO")'="S" D PRT1^ENWOD W @$G(IOF)
30 I $D(ZTQUEUED) S ZTREQ="@" K ^TMP($J)
31 K DA,ENBARCD,ENDA,ENI,ENPRT,ENSHKEY,ENWODA
32 Q
33 ;ENWOME2
Note: See TracBrowser for help on using the repository browser.