source: WorldVistAEHR/trunk/r/PAID-PRS/PRSARPT2.m@ 1166

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

initial load of WorldVistAEHR

File size: 2.2 KB
Line 
1PRSARPT2 ; HISC/FPT-Un-Transmitted Employees Report ;8/14/95 12:03
2 ;;4.0;PAID;;Sep 21, 1995
3 ;
4 ; IEN = employee's internal entry number (file 450)
5 ; NAME = employee's name
6 ; PAGE = page number of report
7 ; PP = pay period
8 ; PPIEN = pay period internal entry number (file 458)
9 ; STATUS = 8b record status
10 ; TL = time and leave unit
11 ; YN = variable to stop terminal scrolling
12 ;
13 K DIC S DIC="^PRST(458,",DIC(0)="AEMQZ" S PPIEN=$P($G(^PRST(458,0)),U,3) I PPIEN<1 D KILL Q
14 S DIC("B")=$P(^PRST(458,PPIEN,0),U,1) D ^DIC K DIC I +Y<1 D KILL Q
15 S PPIEN=+Y
16R0 R !!,"Select T&L Unit (or ALL): ",X:DTIME G:'$T!("^"[X) KILL S X=$TR(X,"al","AL") I X="ALL" S TLE=""
17 E K DIC S DIC="^PRST(455.5,",DIC(0)="EMQ" D ^DIC G KILL:$D(DTOUT),R0:Y<1 S TLE=$P(Y,"^",2)
18 K %ZIS S %ZIS="MQ" W ! D ^%ZIS I POP D KILL Q
19 I $D(IO("Q")) S ZTDESC="8B Un-Transmitted Employees List",ZTRTN="PRINT^PRSARPT2",ZTSAVE("PPIEN")="",ZTSAVE("TLE")="" D ^%ZTLOAD D KILL,HOME^%ZIS Q
20 U IO D PRINT D ^%ZISC
21KILL K %,%ZIS,DIR,DIROUT,DIRUT,DTOUT,DUOUT,IEN,NAME,PAGE,POP,PP,PPIEN,STATUS,TL,TLE,X,Y,YN,ZTDESC,ZTREQ,ZTRTN,ZTSAVE,ZTSTOP
22 Q
23PRINT ; print report
24 I $D(ZTQUEUED) S ZTREQ="@"
25 S PAGE=0,PP=$P(^PRST(458,PPIEN,0),U),YN=""
26 D HEADER I TLE'="" S ATL="ATL"_TLE,TL=TLE G P1
27 S ATL="ATL00" F S ATL=$O(^PRSPC(ATL)) Q:ATL'?1"ATL".E!(YN="^") S TL=$E(ATL,4,6) D P1
28 Q
29P1 S NAME="" F S NAME=$O(^PRSPC(ATL,NAME)) Q:NAME=""!(YN="^") S IEN=0 F S IEN=$O(^PRSPC(ATL,NAME,IEN)) Q:IEN<1!(YN="^") D
30 .S STATUS=$P($G(^PRST(458,PPIEN,"E",IEN,0)),"^",2)
31 .Q:"X"[STATUS
32 .I $Y>(IOSL-4) D:IOST?1."C".E SCROLL D:$D(ZTQUEUED) STOPCHK Q:YN["^" D HEADER
33 .W !,$P($G(^PRSPC(IEN,0)),"^",1),?35,TL,?46,$S(STATUS="T":"Timekeeper",STATUS="P":"Payroll",1:"")
34 Q
35HEADER ; page/screen header
36 W:$Y>0 @IOF
37 S PAGE=PAGE+1 D NOW^%DTC S Y=% X ^DD("DD")
38 W !!,"Un-Transmitted Employees for ",PP,?46,Y,?70,"Page ",PAGE
39 W !,"NAME",?35,"T&L",?46,"STATUS"
40 W !,$$REPEAT^XLFSTR("-",79)
41 Q
42SCROLL ; screen hold
43 K DIR,DIROUT,DIRUT,DTOUT,DUOUT
44 W ! S DIR(0)="E" D ^DIR
45 S:$D(DIRUT)!(Y=0) YN="^"
46 Q
47STOPCHK ; check for user request to stop a background print job
48 I $$S^%ZTLOAD S ZTSTOP=1,YN="^" K ZTREQ W !?10,"*** Output stopped at user's request ***"
49 Q
Note: See TracBrowser for help on using the repository browser.