source: WorldVistAEHR/trunk/r/VOLUNTARY_TIMEKEEPING-ABSV/ABSVOTE.m@ 635

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

initial load of WorldVistAEHR

File size: 2.3 KB
Line 
1ABSVOTE ;VAMC ALTOONA/CTB_CLH - OCCASIONAL TIMEKEEPING ;6/23/94 9:48 AM
2V ;;4.0;VOLUNTARY TIMEKEEPING;;JULY 6, 1994
3OUT K %,%DT,%X,%Y,ABSVXA,ABSVXB,C,D,D0,DA,DDH,DI,DIC,DIE,DLAYGO,DQ,DR,ABSVX,X,Y Q
4GET ;TIME SHEET LOOK-UP
5 K DIC,DIE,DA,D0 S DIC=503336,DIC(0)="AEMNQ",DIC("A")="Select TIME SHEET: ",DIC("S")="I $P(^(0),U,3)=ABSV(""SITE"")"
6 D MDIV^ABSVSITE,^DIC Q:+Y<0
7 S DIE=DIC,DA=+Y
8 Q
9EN ;ENTER OCCASIONAL TIME SHEET ENTRY
10 D ^ABSVSITE G OUT:'%
11EN1 S X=$P(^ABS(503336,0),"^",3) S Y=X+1 F Y=Y:1 L +^ABS(503336,Y):5 Q:$T&('$D(^ABS(503336,Y))) L -^ABS(503336,Y)
12 S X=Y,DIC=503336,DLAYGO=DIC,DIC(0)="L"
13 D MDIV^ABSVSITE,^DIC L -^ABS(503336,Y)
14 K DIC,DLAYGO G:+Y<0 OUT S DA=+Y
15 S DIE="^ABS(503336,",DR="[ABSV OCCASIONAL TIME ENTER]" D ^DIE K DIE
16 I $D(Y) S DIK="^ABS(503336," D ^DIK K DIK
17 S ABSVXA="Add another Occasional Time Sheet Entry",ABSVXB="",%=1 D ^ABSVYN G:%'=1 OUT G EN1
18EDIT ;EDIT OCCASIONAL TIME SHEET
19 D ^ABSVSITE G OUT:'%
20ED1 D GET G:+Y<0 OUT I $P(^ABS(503336,DA,0),"^",9)>1 S ABSVXA="This Time Sheet entry has already been transmitted",ABSVXA(1)="Do you want to continue",ABSVXB="",%=1 D ^ABSVYN G:%'=1 EDIT
21 S ABSVXA="This will mark this Time Sheet entry 'READY FOR TRANSMISSION'",ABSVXA(1)="Do you want to continue",ABSVXB="",%=1 D ^ABSVYN G:%'=1 EDIT
22 S DR="[ABSV OCCASIONAL TIME ENTER]" D ^DIE K DIE,DA
23 S ABSVXA="Edit another Occasional Time Sheet Entry",ABSVXB="",%=2 D ^ABSVYN
24 I %=1 G ED1
25 G OUT
26MARK ;MARK TIME SHEET STATUS AS READY FOR TRANSMISSION
27 D ^ABSVSITE G OUT:'%
28 D GET G:+Y<0 OUT I $P(^ABS(503336,DA,0),"^",9)=1 W !,"TIME SHEET IS ALREADY MARKED FOR TRANSMISSION.",!,"NO FURTHER ACTION REQUIRED.",*7 K DIE G MARK
29 S ABSVXA="Do you want to edit this Time Sheet Entry",ABSVXB="",%=2 D ^ABSVYN
30 I %=1 S DR="[ABSV OCCASIONAL TIME ENTER]" D ^DIE
31 S DR="8////1" D ^DIE S X=" -- TIME SHEET MARKED READY FOR TRANSMISSION --*" D MSG^ABSVQ
32 K DIC,DIE,DA,DR,D0 G MARK
33DELTSE ;DELETE TIME SHEET ENTRY
34 D ^ABSVSITE G OUT:'%
35D1 S DIC=503336,DIC(0)="AEMNQ",DIC("A")="Select TIME SHEET ENTRY: ",DIC("S")="I $P(^(0),U,3)=ABSV(""SITE"")"
36 D MDIV^ABSVSITE,^DIC G:+Y<0 OUT S DA=+Y K DIC
37 S ABSVXA="Are you sure you want to delete this entry",ABSVXB="",%=2 D ^ABSVYN G:%'=1 DELTSE
38 S ABSVXA="ARE YOU SURE",ABSVXB="",%=1 D ^ABSVYN G:%'=1 DELTSE
39 S X="While I delete this entry...." D WAIT^ABSVYN,DEL^ABSVOTSD
40 S X=" <Time sheet has been deleted>*" D MSG^ABSVQ
41 D OUT G D1
Note: See TracBrowser for help on using the repository browser.