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

ACRFEAL.m

Go to the documentation of this file.
ACRFEAL ;IHS/OIRM/DSD/THL,AEF - EDIT AIRLINE FLIGHT; [ 11/01/2001   9:44 AM ]
 ;;2.1;ADMIN RESOURCE MGT SYSTEM;;NOV 05, 2001
 ;;ROUTINE TO ALLOW EDIT OF TRAVEL DAYS
EN D FIELDS
 F  D EN1 Q:$D(ACRQUIT)
EXIT K ACRX,ACRAL0,ACRAL1,ACRALDT,ACRFLDS,ACRY,ACR
 Q
EN1 ;
 D DISP
 S DIR(0)="LO^1:11"
 S DIR("A")="      Edit which fields"
 D DIR^ACRFDIC
 I +Y<1 S ACRQUIT="" Q
 S ACRFLDS=ACRY
 W !
 F J=1:1 S ACRX=$P(ACRFLDS,",",J) Q:ACRX=""  D DIE
 Q
DIE ;
 S DA=ACRDA
 S DIE="^ACRAL("
 S DR=ACR("DR",ACRX)
 I $E(DR)'="[",DR'["T" S DR=DR_"T"
 D DIE^ACRFDIC
 Q
DISP ;DISPLAY TRAVEL DAY INFO
 D GATHER
 W @IOF
 W !?17,@ACRON,"AIRLINE FLIGHT INFORMATION",@ACROF
 W !,"1. DATE ISSUED.: ",$G(ACR(1))
 W !,"2. AIRLINE COMP: ",$G(ACR(2))
 W !,"3. CONTRCT FARE: ",$G(ACR(3))
 W !,"4. FLIGHT COST.: ",$G(ACR(4))
 W !,"5. GTR NO......: ",$G(ACR(5))
 W !,"6. FLIGHT NO...: ",$G(ACR(6))
 W !,"7. DEPART TIME.: ",$G(ACR(7))
 W !,"8. DEPART FROM.: ",$G(ACR(8))
 W !,"9. ARRIVE TIME.: ",$G(ACR(9))
 W !,"10.ARRIVE IN...: ",$G(ACR(10))
 W !,"11.SEAT ASSIGN.: ",$G(ACR(11))
 W !,"--------------------------------------------------------------------------------"
 Q
GATHER ;GATHER TRAVEL DAY INFO
 S ACRAL0=$G(^ACRAL(ACRDA,0))
 S ACRALDT=$G(^ACRAL(ACRDA,"DT"))
 S Y=$P(ACRALDT,U)
 X ^DD("DD")
 S ACR(1)=Y
 S ACR(2)=$P($G(^ACRACOMP(+$P(ACRALDT,U,2),0)),U)
 S ACR(3)=$P(ACRALDT,U,11)
 S ACR(4)=$FN($P(ACRALDT,U,9),"P,",2)
 S ACR(5)=$P(ACRALDT,U,10)
 S ACR(6)=$P(ACRALDT,U,3)
 S Y=$P(ACRALDT,U,4)
 X ^DD("DD")
 S ACR(7)=Y
 S ACR(8)=$P(ACRALDT,U,5)
 I ACR(8) S ACR(8)=$P($G(^ACRPD(ACR(8),0)),U)
 S Y=$P(ACRALDT,U,6)
 X ^DD("DD")
 S ACR(9)=Y
 S ACR(10)=$P(ACRALDT,U,7)
 I ACR(10) S ACR(10)=$P($G(^ACRPD(ACR(10),0)),U)
 S ACR(11)=$P(ACRALDT,U,8)
 Q
FIELDS ;SET FIELDS TO BE EDITED
 S ACR("DR",1)=1
 S ACR("DR",2)=2
 S ACR("DR",3)=11
 S ACR("DR",4)=9
 S ACR("DR",5)=10
 S ACR("DR",6)=3
 S ACR("DR",7)=4
 S ACR("DR",8)=5
 S ACR("DR",9)=6
 S ACR("DR",10)=7
 S ACR("DR",11)=8
 Q