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

ACRFONE.m

Go to the documentation of this file.
ACRFONE ;IHS/OIRM/DSD/THL,AEF - CHECK FOR MULTIPLE DEPARTMENT ACCOUNTS FOR USER; [ 11/01/2001   9:44 AM ]
 ;;2.1;ADMIN RESOURCE MGT SYSTEM;;NOV 05, 2001
 ;;ROUTINE TO CHECK IF USER HAD ACCESS TO MULTIPLE DEPARTMENT ACCOUNTS
EN D EN1
EXIT K ACRJ,ACRX
 Q
EN1 D EN11
 I ACRJ>1 K ACRONE Q
 I ACRJ=1 D  Q
 .S (DA,ACRZDA,ACRFDNO)=ACRONE
 .S ACRFDNA=$P(^ACRLOCB(ACRONE,0),U)
 .S ACRCANDA=$P(^ACRLOCB(ACRONE,"DT"),U,9)
 .S ACRGREF=$P($P(ACRDATA1,";;",3),"(")
 .S ACRY=$P(ACRDATA1,";;",2)
 .D EN^ACRFDTP2
 W !!,*7,"You have not been given access to any accounts."
 W !,"You must have access to at least one account to do data entry."
 W !,"Ask your systems operator for assistance."
 D PAUSE^ACRFWARN
 S ACRQUIT=""
 Q
EN11 S (ACRX,ACRJ)=0
 F  S ACRX=$O(^ACRLOCB("SEC",DUZ,ACRX)) Q:'ACRX!(ACRJ>1)!$D(ACRQUIT)!$D(ACROUT)  D:$D(^ACRLOCB(ACRX,0))
 .S:$P(^ACRLOCB(ACRX,0),U,8)="O" ACRJ=ACRJ+1
 .S ACRONE=ACRX
 Q