source: WorldVistAEHR/trunk/r/NURSING_SERVICE-NUR/NURSEPL1.m@ 1582

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

initial load of WorldVistAEHR

File size: 3.0 KB
Line 
1NURSEPL1 ;HIRMFO/MD,FT-TRAINING REPORT BY LOCATION/SVC POSITION ;8/19/97
2 ;;4.0;NURSING SERVICE;**3,10,13**;Apr 25, 1997
3NPRINT ;
4 S NURFAC="" F S NURFAC=$O(^TMP("NURE",$J,"L",NURFAC)) Q:NURFAC="" D NM Q:$G(NUROUT)
5 Q
6NM S NURPROG="" F S NURPROG=$O(^TMP("NURE",$J,"L",NURFAC,NURPROG)) Q:NURPROG=""!$G(NUROUT) D NN
7 Q
8NN S NURSPEC="" F S NURSPEC=$O(^TMP("NURE",$J,"L",NURFAC,NURPROG,NURSPEC)) Q:NURSPEC=""!$G(NUROUT) D NHDR D NO
9 Q
10NO S NIC="" F S NIC=$O(^TMP("NURE",$J,"L",NURFAC,NURPROG,NURSPEC,NIC)) Q:NIC=""!$G(NUROUT) S NURSORT=$G(^(NIC)) D:NURSORT NP Q:$G(NUROUT) D BRK1
11 Q
12NP D:$Y>(IOSL-6) NHDR Q:$G(NUROUT) W " "_NIC,!! S (NMHOLD,N1)="",NATTEND=0 F S N1=$O(^TMP("NURE",$J,"L1",NURSORT,N1)) Q:N1=""!$G(NUROUT) D NQ
13 Q
14NQ I $Y>(IOSL-6) D NHDR Q:$G(NUROUT) W " "_NIC_" (continued)",!!
15 W " "_$E(N1,1,30) S NATTEND=NATTEND+1,NURSEPC(1)="" F S NURSEPC(1)=$O(^TMP("NURE",$J,"L1",NURSORT,N1,NURSEPC(1))) Q:NURSEPC(1)=""!$G(NUROUT) D NR
16 Q
17NR W:$G(NURSEL(1))'=2 " "_$$CAT^NURSUT2(NURSEPC(1)) I $G(NURSEL(1))=2 W " "_NURSEPC(1)
18 S NCD="",NCD(1)=0 F S NCD=$O(^TMP("NURE",$J,"L1",NURSORT,N1,NURSEPC(1),NCD)) Q:NCD=""!$G(NUROUT) S NLDTPR=$E(NCD,1,7) D NS
19 Q
20NS S NDA=0 F S NDA=$O(^TMP("NURE",$J,"L1",NURSORT,N1,NURSEPC(1),NCD,NDA)) Q:NDA=""!$G(NUROUT) S DATA=^(NDA) D NPPRINT
21 Q
22NPPRINT ;
23 D:NCD(1)&($Y>(IOSL-6)) NHDR W:NLDTPR'=" BLANK" ?35,$E(NLDTPR,4,5)_"/"_$E(NLDTPR,6,7)_"/"_$E(NLDTPR,2,3),?45,$J(+DATA,2,2),?52,$E($P($G(DATA),U,2),1,28),!
24 S NCD(1)=1
25 Q
26BRK1 ;
27 D:$Y>(IOSL-6) NHDR W !,?4,"Total Attendees: ",NATTEND,!!
28 Q
29BRK ;
30 I NURSEL="C"!(NURSEL="A") D
31 .Q:+SHRS("CEU")'>0&(+SHRS("CON")'>0) W ?5,"Location CEUs: ",$J(SHRS("CEU"),4,2)
32 .W ?$S(NURS132:93,1:38),"Location Contact Hours: ",$J(SHRS("CON"),4,2) S RHRS("CEU")=(RHRS("CEU")+SHRS("CEU")),RHRS("CON")=(RHRS("CON")+SHRS("CON")),(SHRS("CEU"),SHRS("CON"))=0
33 .Q
34 Q
35NHDR I '$G(NUROUT),'NURQUEUE,NURSW1,$E(IOST)="C" D ENDPG^NURSUT1 Q:$G(NUROUT)
36 S NURPAGE=NURPAGE+1,NURSW1=1
37 W:$E(IOST)="C"!(NURPAGE>1) @IOF
38 I NURMDSW,$L(NURFAC)>1 W !,?$$CNTR^NURSUT2(NURFAC),$$FACL^NURSUT2(NURFAC)
39 I TYP="S" S X="T" D ^%DT D:+Y D^DIQ W ?$X+2,Y
40 I $G(NURSEL(1))=2 D
41 .W !,$S(NURSEL="M":"MANDATORY ",NURSEL="O":"OTHER ",NURSEL="W":"WARD ",NURSEL="C":"C.E. ",1:"")_"TRAINING REPORT BY SVC. CATEGORY/CLASS FOR "_$S(TYP="C":"CY ",TYP="F":"FY ",1:"")_$S(TYP="C"!(TYP="F"):$G(NYR),1:$G(YRST(1))_"-"_$G(YREND(1)))
42 E W !,$S(NURSEL="M":"MANDATORY ",NURSEL="O":"OTHER ",NURSEL="W":"WARD ",NURSEL="C":"C.E. ",1:"")_"TRAINING REPORT BY UNIT/CLASS FOR "_$S(TYP="C":"CY ",TYP="F":"FY ",1:"")_$S(TYP="C"!(TYP="F"):$G(NYR),1:$G(YRST(1))_"-"_$G(YREND(1)))
43 I TYP'="S" S X="T" D ^%DT D:+Y D^DIQ W ?55,Y
44 W " Page: ",NURPAGE
45 W !,?35,"Date",?45,"Class",!,"Class/Employee",?35,"Attended",?45,"Hours",?52,"Presenter"
46 W !,$$REPEAT^XLFSTR("-",$S(NURS132:132,1:80)),!
47 I $G(NURPLSW),$L(NURPROG)>1 N Z S Z=$$PROD^NURSUT2(NURPROG) W !?$$CNTR^NURSUT2(NURPROG),$G(Z),!,?$$CNTR^NURSUT2(NURPROG),$$REPEAT^XLFSTR("-",$L(Z)+1)
48 Q:$G(NUROUT)
49 W !
50 I NURSPEC'="" W $S($G(NURSEL(1))'=2:"Unit: ",1:"Service Category: ")_NURSPEC,!!
51 Q
Note: See TracBrowser for help on using the repository browser.