DG531110P ;ALB/SJD - DG*5.3*1110 POST-INSTALL ;Oct 2, 2023@14:36
;;5.3;Registration;**1110**;Aug 13, 1993;Build 3
;
; This routine will upload the 2024 Means Test Thresholds and
; Maximum Annual Pension Rates into the MAS PARAMETERS file (#43)
; and the PARAMETERS file (#8989.5).
;
;ICRs
; Reference to BMES^XPDUTL,MES^XPDUTL in ICR #10141
; Reference to ^DIK,IX1^DIK in ICR #10013
; Reference to FILE^DICN in ICR #10009
; Reference to FILE^DIE in ICR #2053
; Reference to EN^XPAR in ICR #2263
;
Q
;
EN ; Entry point for post-install
D BMES^XPDUTL(">>> Beginning the DG*5.3*1110 post-install routine...")
D MT
D MAPR
D BMES^XPDUTL(" ")
D BMES^XPDUTL(">>> Patch DG*5.3*1110 Post-install complete.")
Q
;
MT ; Update Means Test Thresholds
N DA,DIK,DIC,DINUM,DGI,X,Y,DGX,DGREC,DGIENS,DGMESS,DGFDA,DGERR
D BMES^XPDUTL(" ")
D BMES^XPDUTL(" Means Test Thresholds for 2024 calendar year (2023 income year) is being ")
D MES^XPDUTL(" installed in MAS PARAMETERS (#43) file.")
I $D(^DG(43,1,"MT",3240000)) D
.D BMES^XPDUTL(">>> Entry exists for calendar year 2024, entry being deleted")
.D MES^XPDUTL(" and replaced with nationally released thresholds.")
.S DIK="^DG(43,1,""MT"",",DA=3240000,DA(1)=1
.D ^DIK,IX1^DIK
.K DA,DIK
K DO
S DIC="^DG(43,1,""MT"","
S DIC(0)="L"
S DA(1)=1
S (DINUM,X)=3240000
D FILE^DICN
;
I +Y'=3240000 D Q
. D BMES^XPDUTL(" ...Problem encountered adding 2024 thresholds. ")
. D MES^XPDUTL(" - Submit a YOUR IT Services ticket with the Enterprise Service Desk")
. D MES^XPDUTL(" for assistance.")
;
D MES^XPDUTL("")
S DGREC=1
S DGIENS=+Y_","_DGREC_","
F DGI=1:1 S DGX=$P($T(DATA+DGI),";;",2) Q:DGX="QUIT" D
. S DGFDA(43.03,DGIENS,+DGX)=$P(DGX,"^",2)
. S DGMESS(DGI)=" "_$P(DGX,"^",3)_" set to $"_$FN($P(DGX,"^",2),",")_"."
D FILE^DIE(,"DGFDA","DGERR")
I $D(DGERR) D
. D BMES^XPDUTL(" ...Problem encountered adding 2024 thresholds. ")
. D MES^XPDUTL(" - Submit a YOUR IT Services ticket with the Enterprise Service Desk")
. D MES^XPDUTL(" for assistance.")
I '$D(DGERR) D BMES^XPDUTL(.DGMESS)
Q
;
MAPR ; Update Maximum Annual Pension Rates
;
D BMES^XPDUTL(">>> Setting Maximum Annual Pension Rate Parameters in PARAMETERS (#8989.5) file.")
;
;set MAPR rate parameter to 5(%)
D SETPARM("DGMT MAPR GLOBAL RATE",2023,"5")
;
;set MAPR max values
D SETPARM("DGMT MAPR 0 DEPENDENTS",2023,"16551")
D SETPARM("DGMT MAPR 1 DEPENDENTS",2023,"21674")
D SETPARM("DGMT MAPR N DEPENDENTS",2023,"2831")
Q
;
SETPARM(DGPARM,DGINST,DGVALU) ;set PACKAGE entity parameters
;
; Input:
; DGPARM - PARAMETER DEFINITION name
; DGINST - parameter instance
; DGVALU - parameter value
;
; Output:
; None
;
N DGERR
;
; Call to EN^XPAR to set (#8989.5) parameters
D EN^XPAR("PKG",DGPARM,DGINST,DGVALU,.DGERR)
I $G(DGERR) D Q
.D MES^XPDUTL(" "_DGPARM_" parameter, instance "_DGINST_", FAILED! ("_DGVALU_")")
.D MES^XPDUTL(" - Submit a YOUR IT Services ticket with the Enterprise Service Desk")
.D MES^XPDUTL(" for assistance.")
;
I '$G(DGERR) D
.I DGPARM="DGMT MAPR GLOBAL RATE" D
..D MES^XPDUTL(" "_DGPARM_" parameter, instance "_DGINST_", set to "_DGVALU_"%.")
.I DGPARM'="DGMT MAPR GLOBAL RATE" D
..D MES^XPDUTL(" "_DGPARM_" parameter, instance "_DGINST_", set to $"_$FN(DGVALU,",")_".")
Q
;
DATA ; lines to update the MEANS TEST DATA (#43.03) multiple in MAS PARAMETERS (#43) file
;;2^41125^MT COPAY EXEMPT VET INCOME
;;3^8224^MT COPAY EXEMPT 1ST DEP INCOME
;;4^2831^MT COPAY EXEMPT INCOME PER DEP
;;8^80000^THRESHOLD PROPERTY
;;17^14600^CHILD INCOME EXCLUSION
;;QUIT
Q
;
--- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HDG531110P 3730 printed Dec 13, 2024@02:35:57 Page 2
DG531110P ;ALB/SJD - DG*5.3*1110 POST-INSTALL ;Oct 2, 2023@14:36
+1 ;;5.3;Registration;**1110**;Aug 13, 1993;Build 3
+2 ;
+3 ; This routine will upload the 2024 Means Test Thresholds and
+4 ; Maximum Annual Pension Rates into the MAS PARAMETERS file (#43)
+5 ; and the PARAMETERS file (#8989.5).
+6 ;
+7 ;ICRs
+8 ; Reference to BMES^XPDUTL,MES^XPDUTL in ICR #10141
+9 ; Reference to ^DIK,IX1^DIK in ICR #10013
+10 ; Reference to FILE^DICN in ICR #10009
+11 ; Reference to FILE^DIE in ICR #2053
+12 ; Reference to EN^XPAR in ICR #2263
+13 ;
+14 QUIT
+15 ;
EN ; Entry point for post-install
+1 DO BMES^XPDUTL(">>> Beginning the DG*5.3*1110 post-install routine...")
+2 DO MT
+3 DO MAPR
+4 DO BMES^XPDUTL(" ")
+5 DO BMES^XPDUTL(">>> Patch DG*5.3*1110 Post-install complete.")
+6 QUIT
+7 ;
MT ; Update Means Test Thresholds
+1 NEW DA,DIK,DIC,DINUM,DGI,X,Y,DGX,DGREC,DGIENS,DGMESS,DGFDA,DGERR
+2 DO BMES^XPDUTL(" ")
+3 DO BMES^XPDUTL(" Means Test Thresholds for 2024 calendar year (2023 income year) is being ")
+4 DO MES^XPDUTL(" installed in MAS PARAMETERS (#43) file.")
+5 IF $DATA(^DG(43,1,"MT",3240000))
Begin DoDot:1
+6 DO BMES^XPDUTL(">>> Entry exists for calendar year 2024, entry being deleted")
+7 DO MES^XPDUTL(" and replaced with nationally released thresholds.")
+8 SET DIK="^DG(43,1,""MT"","
SET DA=3240000
SET DA(1)=1
+9 DO ^DIK
DO IX1^DIK
+10 KILL DA,DIK
End DoDot:1
+11 KILL DO
+12 SET DIC="^DG(43,1,""MT"","
+13 SET DIC(0)="L"
+14 SET DA(1)=1
+15 SET (DINUM,X)=3240000
+16 DO FILE^DICN
+17 ;
+18 IF +Y'=3240000
Begin DoDot:1
+19 DO BMES^XPDUTL(" ...Problem encountered adding 2024 thresholds. ")
+20 DO MES^XPDUTL(" - Submit a YOUR IT Services ticket with the Enterprise Service Desk")
+21 DO MES^XPDUTL(" for assistance.")
End DoDot:1
QUIT
+22 ;
+23 DO MES^XPDUTL("")
+24 SET DGREC=1
+25 SET DGIENS=+Y_","_DGREC_","
+26 FOR DGI=1:1
SET DGX=$PIECE($TEXT(DATA+DGI),";;",2)
if DGX="QUIT"
QUIT
Begin DoDot:1
+27 SET DGFDA(43.03,DGIENS,+DGX)=$PIECE(DGX,"^",2)
+28 SET DGMESS(DGI)=" "_$PIECE(DGX,"^",3)_" set to $"_$FNUMBER($PIECE(DGX,"^",2),",")_"."
End DoDot:1
+29 DO FILE^DIE(,"DGFDA","DGERR")
+30 IF $DATA(DGERR)
Begin DoDot:1
+31 DO BMES^XPDUTL(" ...Problem encountered adding 2024 thresholds. ")
+32 DO MES^XPDUTL(" - Submit a YOUR IT Services ticket with the Enterprise Service Desk")
+33 DO MES^XPDUTL(" for assistance.")
End DoDot:1
+34 IF '$DATA(DGERR)
DO BMES^XPDUTL(.DGMESS)
+35 QUIT
+36 ;
MAPR ; Update Maximum Annual Pension Rates
+1 ;
+2 DO BMES^XPDUTL(">>> Setting Maximum Annual Pension Rate Parameters in PARAMETERS (#8989.5) file.")
+3 ;
+4 ;set MAPR rate parameter to 5(%)
+5 DO SETPARM("DGMT MAPR GLOBAL RATE",2023,"5")
+6 ;
+7 ;set MAPR max values
+8 DO SETPARM("DGMT MAPR 0 DEPENDENTS",2023,"16551")
+9 DO SETPARM("DGMT MAPR 1 DEPENDENTS",2023,"21674")
+10 DO SETPARM("DGMT MAPR N DEPENDENTS",2023,"2831")
+11 QUIT
+12 ;
SETPARM(DGPARM,DGINST,DGVALU) ;set PACKAGE entity parameters
+1 ;
+2 ; Input:
+3 ; DGPARM - PARAMETER DEFINITION name
+4 ; DGINST - parameter instance
+5 ; DGVALU - parameter value
+6 ;
+7 ; Output:
+8 ; None
+9 ;
+10 NEW DGERR
+11 ;
+12 ; Call to EN^XPAR to set (#8989.5) parameters
+13 DO EN^XPAR("PKG",DGPARM,DGINST,DGVALU,.DGERR)
+14 IF $GET(DGERR)
Begin DoDot:1
+15 DO MES^XPDUTL(" "_DGPARM_" parameter, instance "_DGINST_", FAILED! ("_DGVALU_")")
+16 DO MES^XPDUTL(" - Submit a YOUR IT Services ticket with the Enterprise Service Desk")
+17 DO MES^XPDUTL(" for assistance.")
End DoDot:1
QUIT
+18 ;
+19 IF '$GET(DGERR)
Begin DoDot:1
+20 IF DGPARM="DGMT MAPR GLOBAL RATE"
Begin DoDot:2
+21 DO MES^XPDUTL(" "_DGPARM_" parameter, instance "_DGINST_", set to "_DGVALU_"%.")
End DoDot:2
+22 IF DGPARM'="DGMT MAPR GLOBAL RATE"
Begin DoDot:2
+23 DO MES^XPDUTL(" "_DGPARM_" parameter, instance "_DGINST_", set to $"_$FNUMBER(DGVALU,",")_".")
End DoDot:2
End DoDot:1
+24 QUIT
+25 ;
DATA ; lines to update the MEANS TEST DATA (#43.03) multiple in MAS PARAMETERS (#43) file
+1 ;;2^41125^MT COPAY EXEMPT VET INCOME
+2 ;;3^8224^MT COPAY EXEMPT 1ST DEP INCOME
+3 ;;4^2831^MT COPAY EXEMPT INCOME PER DEP
+4 ;;8^80000^THRESHOLD PROPERTY
+5 ;;17^14600^CHILD INCOME EXCLUSION
+6 ;;QUIT
+7 QUIT
+8 ;