source: FOIAVistA/tag/r/PAID-PRS/PRS8DR.m@ 628

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

initial load of FOIAVistA 6/30/08 version

File size: 3.3 KB
Line 
1PRS8DR ;HISC/MRL,JAH/WCIOFO-DECOMPOSITION, DRIVER ;4/09/2007
2 ;;4.0;PAID;**22,29,56,90,111,112**;Sep 21, 1995;Build 54
3 ;;Per VHA Directive 2004-038, this routine should not be modified.
4 ;
5 ;This routine determines whether or not the parameters necessary
6 ;to decompose time are in existence. The majority of variables
7 ;involving processing an individual employee are defined in this
8 ;routine.
9 ;
10 ;The following lines establish variables necessary to process a
11 ;specific employees time for the specified pay period.
12 ;
13 ;Called by Routines: PRS8, PRS8DR (tag 1)
14 ;
15 N PRVAL,RESTORE
16 ;
17 D ONE^PRS8CV ;clean up variables
18 S SAVE=+$G(SAVE),SEE=+$G(SEE)
19 S TMTD=$G(^PRST(458,+PY,"E",DFN,0)),TMTD=$S($P(TMTD,"^",2)="X":1,1:0)
20 K WK F I=1,2,3 S WK(I)="" ;weekly totals (wk3=misc data)
21 D ^PRSAENT S VAL="" ;get entitlement (ENT)
22 I PP="S" G END ;Manila citizen/don't decompose/no stub
23 I $G(PB)["$" G STUB^PRS8CR ;don't decompose stipend/create stub
24 ; Set NAWS to type of AWS
25 N NAWS
26 S NAWS=0
27 I "KM"[$E(AC,1),$E(AC,2)=1,NH=72 S NAWS="36/40 AWS"
28 I $E(AC,1)="M",$E(AC,2)=2,NH=80 S NAWS="9Mo AWS"
29 ;
30 I "^P^X^"[(U_$P($G(^PRST(458,+PY,"E",DFN,0)),"^",2)_U) S RESTORE=1
31 D AUTOPINI^PRS8(+PY,+DFN,$G(RESTORE),.PRVAL) ; remove auto-posted data
32 S DOUB=0 I $E(ENT,26),$E(ENT,29) S DOUB=1 ;count standby & oncall same
33 S FLX="" S FLX=$P($G(^PRST(458,+PY,"E",DFN,0)),"^",6)
34 I +NAWS=36 S FLX="C"
35 S (SST,TAL)="",X=$P(C0,"^",8) I X'="" D ;T&L Unit
36 .S X=$O(^PRST(455.5,"B",X,0)) ;get ien
37 .S TAL=$G(^PRST(455.5,+X,0)),X=$P(TAL,"^",8) ;get sleep start time
38 .I $L(X) S (NDAY,LAST,Y,Y1)=0 D 15^PRS8SU
39 .S SST=$S(+X:X,1:93) K X,Y1,LAST,X ;sleep start time
40 .K SL,SB,ST ;make sure standby variable don't exist
41 S (CAMISC,CYA,CYA2806,WPCYA,LU)=0 ; << ADDED >> calendar year adjust./leave used in pp
42 S (NH(1),NH(2))=0 ;normal hrs/pp total/week(1)/week(2)
43 S (TH,TH(1),TH(2))=0 ;total hours
44 N CT S (CT(1),CT(2))=0 ; counter for compensatory time
45 K DWK S DWK=0 ;count of days worked - for intermittents
46 S NH=NH/.25 ;turn Norm hrs into 15min increments
47 K TOUR S (TOUR(1),TOUR(2))="" ;tour code for wg/week(1)/week(2)
48 K TYP S TYP="" I $E(ENT)="D"!($E(ENT,1,2)="0D") S TYP=TYP_"D" ;daily pay basis
49 I PP?1N.E!(PP="U") S TYP=TYP_"W" ;wagegrade
50 I PP'="","KM"[PP S TYP=TYP_"N" ;nurse
51 I +$E(AC,2)=1,NH=192 S TYP=TYP_"B" ;baylor plan
52 I $G(PMP)'="","EF"[PMP S TYP=TYP_"H" ;Nurse Hybrid
53 I $E($G(AC),2)=3 S TYP=TYP_"I" ;intermittent
54 I NH>320 S TYP=TYP_"F" I NH'>448 S TYP=TYP_"f" ;firefighter
55 ; Nurses on the 9month AWS will be treated as FT employees during the 9 months
56 ; that they are working. Prevent a "P" from being added to TYP.
57 I NH,NH'>319,$E(AC,2)'=1 S TYP=TYP_"P" ;part-time
58 I PP="L",$E(AC,2)=2 S TYP=TYP_"d" ;doctor
59 I PP="L",$E(AC,2)=1 S TYP=TYP_"dR" ;doctor/resident or intern
60 S (PTH,PTH(1),PTH(2))=0 ;part-time hours
61 K WKL S (WKL(1),WKL(2))=0 ;count leave used in week during ND hours
62 K MEAL S $P(MEAL,"1^",14)="",MEAL=MEAL_1 ;mealtime
63 S (MILV,WCMP)=0 ;ML and PC indicators
64 S (CBCK(1),CBCK(2))=0 ;call back hrs by week counter
65 I TYP="" S TYP="*"
66 K I,PB,PP,X,X1,X2
67 D ^PRS8SU ;set up employee variables and commence decomposing
68 D ^PRS8CR
69 D:$D(PRVAL) AUTOPRES^PRS8(+PY,+DFN,.PRVAL) ; restore auto-posted data
70 I SEE D ^PRS8VW
71 ;
72END ; --- This is where we end this process
73 G ONE^PRS8CV ;clean up
74 Q
75 ;
761 ; --- enter here to print single entry and close device
77 D ^PRS8DR,^%ZISC Q
Note: See TracBrowser for help on using the repository browser.