source: FOIAVistA/trunk/r/IFCAP-PRC-PRX--PRCA--PRCN/PRCHRCS.m@ 1783

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

initial load of FOIAVistA 6/30/08 version

File size: 3.2 KB
Line 
1PRCHRCS ;SF/TKW-PRINT REPORTS SHOWING PPM WHAT LOG CODE SHEETS NEED TO BE GENERATED ;9/12/96
2V ;;5.1;IFCAP;;Oct 20, 2000
3 ;Per VHA Directive 10-93-142, this routine should not be modified.
4 ;
5EN S PRCHSAVQ=PRCHQ,PRCHQ=PRCHQ_"^PRCHRCS",PRCHQ("DEST")="S" D ^PRCHQUE
6 W !!!,$C(7),"After checking the report, you will need to purge the NONEXPENDABLE",!,"entries from the list. Since the codesheets for NONEXPENDABLE goods have",!
7 W "not yet been programmed, the stations must use either FALCON, or the",!,"KEYPUNCH A CODESHEET option to create these entries, rather than this",!,"option. Therefore, they no longer need to be on the list.",!
8 S %A="Delete NONEXPENDABLE entries from list",%B="Answer YES if you do not want to see these entries on the next report",%=1 D YN^PRCFYN I %'=1 G Q2
9 S PRCH=$S(PRCHSAVQ["EN1":"AE",PRCHSAVQ["EN2":"AF",1:"") I PRCH="" G Q2
10 F PRCHPO=0:0 S PRCHPO=$O(^PRC(442,PRCH,"N",PRCHPO)) Q:'PRCHPO I $D(^PRC(442,PRCHPO,0)),+^(0)=PRC("SITE"),$D(^(1)),$P(^(1),U,18)="N" W $P(^(0),U,1),! D DEL
11 ;
12Q2 K PRCH,PRCHSAVQ,PRCHQ Q
13 ;
14EN1 ;PRINT REPORT OF ACQUISITIONS CODE SHEETS TO BE DONE
15 S PRCHRPT=1,PRCH="AE" G RD
16 ;
17EN2 ;PRINT REPORT OF RECV.REPORT CODE SHEETS TO BE DONE
18 S PRCHRPT=2,PRCH="AF"
19 ;
20RD K ^TMP($J) S Y=DT D DD^%DT S PRCHDT=Y,PRCHPAGE=0 D HD
21 F PRCHPO=0:0 S PRCHPO=$O(^PRC(442,PRCH,"N",PRCHPO)) Q:'PRCHPO D
22 .I $D(^PRC(442,PRCHPO,0)) S X=$P(^(0),U,1)
23 .Q:$P($G(^PRC(442,PRCHPO,0)),"^",2)=25
24 .I +$G(X)=PRC("SITE") S ^TMP($J,$P(X,"-",2))=PRCHPO I $D(^PRC(442,PRCHPO,1)),$P(^(1),U,18)="N" S $P(^TMP($J,$P(X,"-",2)),U,2)="**"
25 S PRCHPONO=""
26 F J=0:0 S PRCHPONO=$O(^TMP($J,PRCHPONO)) Q:PRCHPONO="" S PRCHPO=$P(^(PRCHPONO),U,1),PRCHNON=$P(^(PRCHPONO),U,2) D P1 I PRCHRPT=2 F PRCHFPT=0:0 S PRCHFPT=$O(^PRC(442,"AF","N",PRCHPO,PRCHFPT)) Q:'PRCHFPT D P2
27 G Q
28 ;
29P1 D:PRCHDY>60 HD
30 W !,?1,PRCHNON,?4,PRCHPONO D PODATA W ?15,Y,?30,PRCHMOP,?62,PRCHSFC,!,?7,PRCHVND S PRCHDY=PRCHDY+2 I PRCHRPT=1 W ! S PRCHDY=PRCHDY+1
31 Q
32 ;
33PODATA S X=^PRC(442,PRCHPO,0)
34 S PRCHMOP=$P($G(^PRCD(442.5,+$P(X,U,2),0)),U,1)
35 S Y=$P(^DD(442,.03,0),U,3),PRCHSFC=$P(X,U,19) I PRCHSFC F I=1:1 S X=$P(Y,";",I) Q:X="" I $P(X,":",1)=PRCHSFC S PRCHSFC=$P(X,":",2) Q
36 S Y=$G(^PRC(442,PRCHPO,1)),PRCHVND=$P($G(^PRC(440,+Y,0)),U,1),Y=+$P(Y,U,15) D DD^%DT
37 Q
38 ;
39P2 Q:'$D(^PRC(442,PRCHPO,11,PRCHFPT,0)) S Y=+^(0) D DD^%DT S PRCHRDT=Y D:PRCHDY>60 HD W ?45,$J(PRCHFPT,6),?57,PRCHRDT,! S PRCHDY=PRCHDY+1
40 Q
41 ;
42HD S PRCHPAGE=PRCHPAGE+1 W @IOF,$S(PRCHRPT=1:"ACQUISITIONS",1:"RECEIVING REPORTS")_" NEEDING LOG CODE SHEETS--STATION: ",PRC("SITE"),?67,PRCHDT,?88,"PAGE ",PRCHPAGE,!
43 W ?1,"(NOTE: ** INDICATES NONEXPENDABLE ORDERS)",!
44 W ?4,"P.O.NO.",?15,"P.O.DATE",?30,"METHOD OF PROCESSING",?62,"SPECIAL FUND CONTROL POINT",!,?7,"VENDOR"
45 I PRCHRPT=2 W ?45,"PARTIAL",?57,"DATE RECEIVED"
46 W ! F J=0:1:(IOM-2) W "-"
47 W ! S PRCHDY=5
48 Q
49 ;
50Q W $C(13),! K X,Y,I,J,PRCH,PRCHDT,PRCHDY,PRCHFPT,PRCHMOP,PRCHNON,PRCHPAGE,PRCHPO,PRCHPONO,PRCHRDT,PRCHRPT,PRCHSFC,PRCHVND
51 I $D(ZTSK) D KILL^%ZTLOAD
52 Q
53 ;
54DEL ;DELETE NON-EXPENDABLE ORDERS FROM LIST OF ORDERS NEEDING CODE-SHEETS PROCESSED.
55 I PRCH="AE" S DIE="^PRC(442,",DA=PRCHPO,DR="103.5///@" D ^DIE K DIE,DA,DR Q
56 F PRCHFPT=0:0 S PRCHFPT=$O(^PRC(442,"AF","N",PRCHPO,PRCHFPT)) Q:'PRCHFPT S DIE="^PRC(442,"_PRCHPO_",11,",DA(1)=PRCHPO,DA=PRCHFPT,DR="19.2///@" D ^DIE K DIE,DA,DR
57 Q
Note: See TracBrowser for help on using the repository browser.