XMYPRE ;ISC-SF/GMB-Pre- & Post- Init ;08/29/2002 09:03
;;8.0;MailMan;;Jun 28, 2002
PRE ; Pre-init
K ^DD(4.21,2,3) ; Kill errant help node.
K ^DD(3.7,2,1,1,1.2) ; Kill obsolete node.
K ^DD(3.811,0,"NM","MEMBER GROUP") ; Kill errant name.
Q:'$D(^DD(3.702,6,1,1,1)) ; Quit if the pre-init has run already
D OPTION
D DELFLDS
D ACXREF
Q
OPTION ; Clean up some MailMan options
N XMOPT,XMIEN,XMFDA,XMIENS
F XMOPT="XMQSHOW","XMSUBEDIT","XMDXPROT" D
. S XMIEN=$O(^DIC(19,"B",XMOPT,0)) Q:'XMIEN
. S XMIENS=XMIEN_","
. S XMFDA(19,XMIENS,15)="@" ; EXIT ACTION
. ;S XMFDA(19,XMIENS,20)="@" ; ENTRY ACTION
. D FILE^DIE("","XMFDA")
F XMOPT="XMMGR-IN-BASKET-PURGE" D
. S XMIEN=$O(^DIC(19,"B",XMOPT,0)) Q:'XMIEN
. S XMIENS=XMIEN_","
. S XMFDA(19,XMIENS,3.7)="@" ; HELP FRAME
. D FILE^DIE("","XMFDA")
Q
DELFLDS ; Delete fields no longer used.
S DIK="^DD(4.2999,",DA=7,DA(1)=4.2999 D ^DIK ; OUTGOING MESSAGE COUNT
S DIK="^DD(4.2999,",DA=8,DA(1)=4.2999 D ^DIK ; CHARACTERS REC'D
S DIK="^DD(4.2999,",DA=9,DA(1)=4.2999 D ^DIK ; INCOMING MESSAGE COUNT
S DIK="^DD(4.2999,",DA=10,DA(1)=4.2999 D ^DIK ; CHARACTERS SENT
N I
S I=0
F S I=$O(^XMBS(4.2999,I)) Q:'I S ^XMBS(4.2999,I,0)=I
Q
ACXREF ; Delete old AC xref for NETWORK PRIORITY TRANSMISSION field.
D DELIX^DDMOD(3.702,6,1) ; delete the DD, leave the data
N XMK,XMZ ; Reposition the xref to match the new definition.
S XMK=0
F S XMK=$O(^XMB(3.7,.5,2,"AC",1,XMK)) Q:'XMK D
. S XMZ=0
. F S XMZ=$O(^XMB(3.7,.5,2,"AC",1,XMK,XMZ)) Q:'XMZ D
. . K ^XMB(3.7,.5,2,"AC",1,XMK,XMZ)
. . S ^XMB(3.7,.5,2,XMK,1,"AC",1,XMZ)=""
Q
POST ; Post-init
D INIT^XMC
D KEYS
D DIALOG
Q
KEYS ; Security Keys
; KIDS does not correctly transport the 'mutually exclusive' field,
; so we have to correct it.
N XMSTAR,XMSTARL,XMFDA,I
S XMSTAR=$$FIND1^DIC(19.1,"","QX","XMSTAR")
S XMSTARL=$$FIND1^DIC(19.1,"","QX","XMSTAR LIMITED")
S I=$O(^DIC(19.1,XMSTAR,5,0))
S XMFDA(19.15,I_","_XMSTAR_",",.01)=XMSTARL
D FILE^DIE("","XMFDA")
S I=$O(^DIC(19.1,XMSTARL,5,0))
S XMFDA(19.15,I_","_XMSTARL_",",.01)=XMSTAR
D FILE^DIE("","XMFDA")
Q
DIALOG ; Delete DIALOG file entries. KIDS fails to do this.
N DIK,DA
S DIK="^DI(.84,"
F DA=34425,34443,34443.1 D ^DIK
Q
--- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HXMYPRE 2280 printed Dec 13, 2024@02:14:33 Page 2
XMYPRE ;ISC-SF/GMB-Pre- & Post- Init ;08/29/2002 09:03
+1 ;;8.0;MailMan;;Jun 28, 2002
PRE ; Pre-init
+1 ; Kill errant help node.
KILL ^DD(4.21,2,3)
+2 ; Kill obsolete node.
KILL ^DD(3.7,2,1,1,1.2)
+3 ; Kill errant name.
KILL ^DD(3.811,0,"NM","MEMBER GROUP")
+4 ; Quit if the pre-init has run already
if '$DATA(^DD(3.702,6,1,1,1))
QUIT
+5 DO OPTION
+6 DO DELFLDS
+7 DO ACXREF
+8 QUIT
OPTION ; Clean up some MailMan options
+1 NEW XMOPT,XMIEN,XMFDA,XMIENS
+2 FOR XMOPT="XMQSHOW","XMSUBEDIT","XMDXPROT"
Begin DoDot:1
+3 SET XMIEN=$ORDER(^DIC(19,"B",XMOPT,0))
if 'XMIEN
QUIT
+4 SET XMIENS=XMIEN_","
+5 ; EXIT ACTION
SET XMFDA(19,XMIENS,15)="@"
+6 ;S XMFDA(19,XMIENS,20)="@" ; ENTRY ACTION
+7 DO FILE^DIE("","XMFDA")
End DoDot:1
+8 FOR XMOPT="XMMGR-IN-BASKET-PURGE"
Begin DoDot:1
+9 SET XMIEN=$ORDER(^DIC(19,"B",XMOPT,0))
if 'XMIEN
QUIT
+10 SET XMIENS=XMIEN_","
+11 ; HELP FRAME
SET XMFDA(19,XMIENS,3.7)="@"
+12 DO FILE^DIE("","XMFDA")
End DoDot:1
+13 QUIT
DELFLDS ; Delete fields no longer used.
+1 ; OUTGOING MESSAGE COUNT
SET DIK="^DD(4.2999,"
SET DA=7
SET DA(1)=4.2999
DO ^DIK
+2 ; CHARACTERS REC'D
SET DIK="^DD(4.2999,"
SET DA=8
SET DA(1)=4.2999
DO ^DIK
+3 ; INCOMING MESSAGE COUNT
SET DIK="^DD(4.2999,"
SET DA=9
SET DA(1)=4.2999
DO ^DIK
+4 ; CHARACTERS SENT
SET DIK="^DD(4.2999,"
SET DA=10
SET DA(1)=4.2999
DO ^DIK
+5 NEW I
+6 SET I=0
+7 FOR
SET I=$ORDER(^XMBS(4.2999,I))
if 'I
QUIT
SET ^XMBS(4.2999,I,0)=I
+8 QUIT
ACXREF ; Delete old AC xref for NETWORK PRIORITY TRANSMISSION field.
+1 ; delete the DD, leave the data
DO DELIX^DDMOD(3.702,6,1)
+2 ; Reposition the xref to match the new definition.
NEW XMK,XMZ
+3 SET XMK=0
+4 FOR
SET XMK=$ORDER(^XMB(3.7,.5,2,"AC",1,XMK))
if 'XMK
QUIT
Begin DoDot:1
+5 SET XMZ=0
+6 FOR
SET XMZ=$ORDER(^XMB(3.7,.5,2,"AC",1,XMK,XMZ))
if 'XMZ
QUIT
Begin DoDot:2
+7 KILL ^XMB(3.7,.5,2,"AC",1,XMK,XMZ)
+8 SET ^XMB(3.7,.5,2,XMK,1,"AC",1,XMZ)=""
End DoDot:2
End DoDot:1
+9 QUIT
POST ; Post-init
+1 DO INIT^XMC
+2 DO KEYS
+3 DO DIALOG
+4 QUIT
KEYS ; Security Keys
+1 ; KIDS does not correctly transport the 'mutually exclusive' field,
+2 ; so we have to correct it.
+3 NEW XMSTAR,XMSTARL,XMFDA,I
+4 SET XMSTAR=$$FIND1^DIC(19.1,"","QX","XMSTAR")
+5 SET XMSTARL=$$FIND1^DIC(19.1,"","QX","XMSTAR LIMITED")
+6 SET I=$ORDER(^DIC(19.1,XMSTAR,5,0))
+7 SET XMFDA(19.15,I_","_XMSTAR_",",.01)=XMSTARL
+8 DO FILE^DIE("","XMFDA")
+9 SET I=$ORDER(^DIC(19.1,XMSTARL,5,0))
+10 SET XMFDA(19.15,I_","_XMSTARL_",",.01)=XMSTAR
+11 DO FILE^DIE("","XMFDA")
+12 QUIT
DIALOG ; Delete DIALOG file entries. KIDS fails to do this.
+1 NEW DIK,DA
+2 SET DIK="^DI(.84,"
+3 FOR DA=34425,34443,34443.1
DO ^DIK
+4 QUIT