source: WorldVistAEHR/trunk/r/PROSTHETICS-RMPR-RMPO-RMPS/RMPRPAT6.m@ 619

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

initial load of WorldVistAEHR

File size: 2.7 KB
Line 
1RMPRPAT6 ;PHX/JLT-DISPLAY JOB RECORD INFO ;10/19/1993
2 ;;3.0;PROSTHETICS;;Feb 09, 1996
3 S (PAGE,MC,LC,TMC,TLC)=0 D HDR^RMPR29W(RJDA)
4ITD G:($Y+6>IOSL) MORE D ITM S RMPRWO=$P(RCK(RI),U,3)
5TCH G:'$D(TECH(RMPRWO))!($O(TECH(RMPRWO,0))'>0) MU S RTCD=$O(TECH(RMPRWO,0))
6 G:($Y+6>IOSL) MORE S RTC=$O(TECH(RMPRWO,RTCD,664.33,0)) I RTC D TDSP G TCH
7MU G:($Y+6>IOSL) MORE I $D(TMP(RMPRWO,664.22)) S RJ=$O(TMP(RMPRWO,664.22,0)) I RJ D MDSP G MU
8EXT G:($Y+6>IOSL) MORE S RW=$O(^UTILITY($J,"TEXT",RMPRWO,0)) I RW D WDSP G EXT
9 W !,RMPR("L")
10MORE ;DISPLAY MORE INFO
11 I IOST["C-" I $Y<21 F W ! Q:$Y>21
12 I IOST["C-" W $C(7) R X:DTIME I '$T G EXIT
13 S RMPRWO=$P(RCK(RI),U,3)
14 I $D(^UTILITY($J,"TEXT",RMPRWO)) S RMPRWZ=1
15 I $D(TECH(RMPRWO)) S RMPRTZ=1
16 I $D(TMP(RMPRWO,664.22)) S RMPRIZ=1
17 I $D(RMPRTZ) K RMPRTZ,RMPRIZ,RMPRCZ,RMPRWZ D HDR^RMPR29W(RJDA),ITM G TCH
18 I $D(RMPRIZ) K RMPRIZ,RMPRCZ,RMPRWZ D HDR^RMPR29W(RJDA),ITM G MU
19 I $D(RMPRWZ) K RMPRWZ,RMPRCZ D HDR^RMPR29W(RJDA),ITM G EXT
20 G EXIT
21ITM ;DISPLAY ITEM
22 W !,"JOB#:",?6,"("_RI_")",?10,"ITM#: "_$P(RCK(RI),U),?25,$E(^UTILITY("DIQ1",$J,664.16,$P(RCK(RI),U,4),.01),1,25),?54,"DATE MEASURED: "_$$FMTE^XLFDT(^UTILITY("DIQ1",$J,664.2,$P(RCK(RI),U,3),10,"I"),2)
23 W !,"DATE COMPLETED: "_$$FMTE^XLFDT(^UTILITY("DIQ1",$J,664.2,$P(RCK(RI),U,3),8,"I"),2)
24 W ?25,"COMPLETED BY: "_$E(^UTILITY("DIQ1",$J,664.2,$P(RCK(RI),U,3),9,"E"),1,14),?54,"CHECKED BY: "_$E(^UTILITY("DIQ1",$J,664.2,$P(RCK(RI),U,3),11,"E"),1,14),!
25 D AMC^RMPR293
26 Q
27MDSP ;DISPLAY MATERIALS
28 W !,"MATERIALS:",?15,$E(TMP(RMPRWO,664.22,RJ,.01),1,20),?37,TMP(RMPRWO,664.22,RJ,1),?42,TMP(RMPRWO,664.22,RJ,6),?47,$E(TMP(RMPRWO,664.22,RJ,3),1),?53,$J(TMP(RMPRWO,664.22,RJ,2),7,2)
29 S MC=TMP(RMPRWO,664.22,RJ,1)*TMP(RMPRWO,664.22,RJ,2),TMC=TMC+MC W ?64,"TOTAL:",?69,$J(MC,10,2) K TMP(RMPRWO,664.22,RJ)
30 I $G(TMP(RMPRWO,664.22,RJ,10))'="" S RVA=$O(^RMPR(660,"E",TMP(RMPRWO,664.22,RJ,10),0)) I $D(^RMPR(660,+RVA,0)) S RDEL=$P(^(0),U,12) W !,?15,TMP(RMPRWO,664.22,RJ,10),?37,"DATE DELIVERED: ",?53,$$FMTE^XLFDT(RDEL,2)
31 K TMP(RMPRWO,664.22,RJ) Q
32TDSP ;DISPLAY TECHNICIAN
33 W !,$$FMTE^XLFDT(RTCD,2)
34 W ?15,$E(TECH(RMPRWO,RTCD,664.33,RTC,.01,"E"),1,20),?37,"HRS",?42,TECH(RMPRWO,RTCD,664.33,RTC,1,"E"),?47,"RATE:"
35 S RTR=$P($G(^RMPR(669.2,TECH(RMPRWO,RTCD,664.33,RTC,.01,"I"),0)),U,3) W ?53,$J(RTR,7,0) S LC=TECH(RMPRWO,RTCD,664.33,RTC,1,"I")*RTR,TLC=TLC+LC
36 W ?64,"TOTAL:",$J(LC,10,2) K TECH(RMPRWO,RTCD,664.33,RTC) S RTHD=RTCD
37 Q
38WDSP ;DISPLAY REMARKS FIELD
39 W !,^UTILITY($J,"TEXT",RMPRWO,RW) K ^UTILITY($J,"TEXT",RMPRWO,RW),RR Q
40EXIT ;EXIT ROUTINE
41 W !,?45,"TOTAL LABOR COST: ",?69,$J(TLC,10,2)
42 W !,?45,"TOTAL MATERIAL COST:",?69,$J(TMC,10,2)
43 W !,?45,"TOTAL COST",?69,$J(TLC+TMC,10,2)
44 R !,"Press any key to continue ",CONT:DTIME
45 Q
Note: See TracBrowser for help on using the repository browser.