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

ACRFPRS.m

Go to the documentation of this file.
ACRFPRS ;IHS/OIRM/DSD/THL,AEF - PRINT PAY ROLL SUMMARY; [ 09/23/2005   9:44 AM ]
 ;;2.1;ADMIN RESOURCE MGT SYSTEM;**19**;NOV 05, 2001
 ;;ROUTINE TO PRINT PAY ROLL SUMMARY
EN N ACRI,ACRY
 S ACRXCUT="I $E($G(IOST),1,2)=""C-"" D PAUSE^ACRFWARN"
 S ACRX=$P(^ACRDOC(ACRDOCDA,0),U,14)
 S ACREMP=$P(^ACRDOC(ACRDOCDA,"PR"),U)
 ;S ACREMP=$P(^VA(200,ACREMP,0),U)  ;ACR*2.1*19.02 IM16848
 S ACREMP=$$NAME2^ACRFUTL1(ACREMP)  ;ACR*2.1*19.02 IM16848
 S ACREMP=$P(ACREMP,",",2)_" "_$P(ACREMP,",")
 S ACRFY=$P(ACRX,"-",2)
 D HEAD
 D EN1
 D TAIL
 X ACRXCUT
EXIT K ACRBEN,ACRXCUT,ACRY,ACRTOT,ACRTSAL,ACRTBEN,ACRSS,ACRKW,ACRSAL,ACRX,ACREMP,ACRFY
 Q
EN1 S (ACRY,ACRTOT,ACRTSAL,ACRTBEN)=0
 F  S ACRY=$O(^ACRSS("C",ACRDOCDA,ACRY)) Q:'ACRY  D W
 Q
W S ACRSS=^ACRSS(ACRY,0)
 S ACRKW=$P(^ACRSS(ACRY,"NMS"),U,5)
 S ACRSAL=$P(^ACRSS(ACRY,"DT"),U,4)
 S ACRTSAL=ACRTSAL+ACRSAL
 S ACRY=$O(^ACRSS("C",ACRDOCDA,ACRY))
 S ACRBEN=$P(^ACRSS(ACRY,"DT"),U,4)
 S ACRTBEN=ACRTBEN+ACRBEN
 S ACRTOT=ACRTOT+ACRBEN+ACRSAL
 W !?5,$P(ACRSS,U)
 W ?34,"| ",$J($FN(ACRSAL,"P",2),10)
 W ?49,"| ",$J($FN(ACRBEN,"P",2),10)
 X ACRXCUT
 D HEAD
 Q
 W !,"PAY ROLL SUMMARY FOR:  ",ACREMP
 W $$DASH^ACRFMENU
 W !?5,"PAY PERIOD (FOR FY ",ACRFY,"): "
 W ?34,"|    SALARY"
 W ?49,"|  BENEFITS"
 W $$DASH^ACRFMENU
 Q
TAIL W $$DASH^ACRFMENU
 W !?34,"| ",$J($FN(ACRTSAL,"P",2),10)
 W ?49,"| ",$J($FN(ACRTBEN,"P",2),10)
 W !?25,"TOTAL: "
 W ?36,$J($FN(ACRTOT,"P",2),10)
 Q