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

FSCUM.m

Go to the documentation of this file.
  1. FSCUM ;SLC/STAFF-NOIS Utilities Maintenance ;9/27/96 17:26
  1. ;;1.1;NOIS;;Sep 06, 1998
  1. ;
  1. DELETE ; from programmer
  1. N CALL,CALLNAME,DIC,X,Y K DIC
  1. S DIC=7100,DIC(0)="AEMOQ",DIC("A")="Select NOIS call to be deleted: "
  1. D ^DIC Q:Y<1
  1. K DIC
  1. S CALL=+Y,CALLNAME=$P(Y,U,2)
  1. N DIR,X,Y
  1. W !!,CALL,!,CALLNAME
  1. Q
  1. ;
  1. PURGE ;
  1. K ^TMP("FSC PURGE",$J)
  1. N LIST,NUM,OK
  1. D WARNING(.OK)
  1. I 'OK D NOTDONE Q
  1. D LIST(.LIST,.NUM,.OK)
  1. I 'OK D NOTDONE Q
  1. I 'NUM W !,"No calls on this list.",! Q
  1. W !,NUM," calls will be deleted."
  1. D ASK(.OK)
  1. I 'OK D NOTDONE Q
  1. D WIPEOUT
  1. K ^TMP("FSC PURGE",$J)
  1. Q
  1. ;
  1. WARNING(OK) ;
  1. N DIR,X,Y K DIR
  1. S OK=0
  1. W !,"WARNING!!!! This option is used to PURGE calls.",$C(7),!
  1. S DIR(0)="YA0",DIR("A")="Are you sure you want to do this? ",DIR("B")="NO"
  1. S DIR("?",1)="Enter YES to get a list to purge."
  1. S DIR("?",2)="Enter or '^' to exit."
  1. S DIR("?")="^D HELP^FSCU(.DIR)"
  1. S DIR("??")="FSC U1 NOIS"
  1. D ^DIR K DIR
  1. I Y=1 S OK=1
  1. Q
  1. ;
  1. LIST(LIST,NUM,OK) ;
  1. S LIST="",(NUM,OK)=0
  1. N CALL,LIMIT
  1. D LIST^FSCULOOK(.LIST,.LIMIT,.OK)
  1. I 'OK Q
  1. S LIST=+LIST
  1. S CALL=0 F S CALL=$O(^FSCD("LISTS","ALC",LIST,CALL)) Q:CALL<1 D
  1. .S ^TMP("FSC PURGE",$J,CALL)=""
  1. .S NUM=NUM+1
  1. Q
  1. ;
  1. ASK(OK) ;
  1. N DIR,X,Y K DIR
  1. S OK=0
  1. W !,"WARNING!!!! This will purge the calls in this list.",$C(7),!
  1. S DIR(0)="YA0",DIR("A")="Are you sure you want to do this? ",DIR("B")="NO"
  1. S DIR("?",1)="Enter YES to purge these calls."
  1. S DIR("?",2)="Enter or '^' to exit."
  1. S DIR("?")="^D HELP^FSCU(.DIR)"
  1. S DIR("??")="FSC U1 NOIS"
  1. D ^DIR K DIR
  1. I Y=1 S OK=1
  1. Q
  1. ;
  1. WIPEOUT ;
  1. N CALL
  1. S CALL=0 F S CALL=$O(^TMP("FSC PURGE",$J,CALL)) Q:CALL<1 D
  1. .W !,$P($G(^FSCD("CALL",CALL,0)),U)
  1. .Q ; ****
  1. .M ^FSCD("ZZPURGE",CALL)=^FSCD("CALL",CALL)
  1. .D DELETE^FSCUCD(CALL)
  1. Q
  1. ;
  1. NOTDONE ;
  1. W !,"No calls were purged."
  1. Q