- BMC4P1 ;IHS/ITSC/FCJ - BMC 4.0 PATCH 1 ; [ 06/02/2006 2:07 PM ]
- ;;4.0;REFERRED CARE INFO SYSTEM;**1**;JUN 01, 2006
- ;
- ;
- I '$G(IOM) D HOME^%ZIS
- ;
- I '$G(DUZ) W !,"DUZ UNDEFINED OR 0." D SORRY(2) Q
- ;
- I '$L($G(DUZ(0))) W !,"DUZ(0) UNDEFINED OR NULL." D SORRY(2) Q
- ;
- I '(DUZ(0)["@") W:'$D(ZTQUEUED) !,"DUZ(0) DOES NOT CONTAIN AN '@'." D SORRY(2) Q
- ;
- S X=$$GET1^DIQ(200,DUZ,.01)
- W !!,$$CJ^XLFSTR("Hello, "_$P(X,",",2)_" "_$P(X,","),IOM)
- W !!,$$CJ^XLFSTR("Checking Environment for "_$P($T(+2),";",4)_" V "_$P($T(+2),";",3)_".",IOM)
- ;
- NEW IORVON,IORVOFF
- S X="IORVON;IORVOFF"
- D ENDR^%ZISS
- ;
- I $$VCHK("BMC","4.0",2,"'=")
- I $$VCHK("XU","8.0",2,"<")
- I $$VCHK("DI","21.0",2,"<")
- I $$VCHK("ATX","5.1",2,"<")
- I $$VCHK("AUPN","99.1",2,"<")
- ;
- NEW DA,DIC
- S X="BMC",DIC="^DIC(9.4,",DIC(0)="",D="C"
- D IX^DIC
- I Y<0,$D(^DIC(9.4,"C","BMC")) D
- . W !!,*7,*7,$$CJ^XLFSTR("You Have More Than One Entry In The",IOM),!,$$CJ^XLFSTR("PACKAGE File with an ""BMC"" prefix.",IOM)
- . W !,$$CJ^XLFSTR(IORVON_"One entry needs to be deleted."_IORVOFF,IOM)
- . D SORRY(2)
- ;
- I $G(XPDQUIT) W !,$$CJ^XLFSTR(IORVON_"FIX IT! Before Proceeding."_IORVOFF,IOM),!!,*7,*7,*7 Q
- ;
- W !!,$$CJ^XLFSTR("ENVIRONMENT OK.",IOM)
- ;
- D HELP^XBHELP("INTROE","BMC4P1")
- I '$$DIR^XBDIR("E","","","","","",1) D SORRY(2) Q
- ;
- I $G(XPDENV)=1 S (XPDDIQ("XPZ1"),XPDDIQ("XPZ2"))=0 D HELP^XBHELP("INTROI","BMC4P1") I '$$DIR^XBDIR("E","","","","","",1) D SORRY(2)
- ;
- Q
- ;
- SORRY(X) ;
- KILL DIFQ
- S XPDQUIT=X
- W *7,!,$$CJ^XLFSTR("Sorry....FIX IT!",IOM)
- Q
- ;
- VCHK(BMCPRE,BMCVER,BMCQUIT,BMCCOMP) ; Check versions needed.
- ;
- NEW BMCV
- S BMCV=$$VERSION^XPDUTL(BMCPRE)
- W !,$$CJ^XLFSTR("Need "_$S(BMCCOMP="<":"at least ",1:"")_BMCPRE_" v "_BMCVER_"....."_BMCPRE_" v "_BMCV_" Present",IOM)
- I @(BMCV_BMCCOMP_BMCVER) D SORRY(BMCQUIT) Q 0
- Q 1
- ;
- PRE ;EP - From KIDS.
- I $$NEWCP^XPDUTL("PRE1","AUDS^BMC4P1")
- ; The following line prevents the "Disable Options..." and "Move
- ; Routines..." questions from being asked during the install.
- I $G(XPDENV)=1 S (XPDDIQ("XPZ1"),XPDDIQ("XPZ2"))=0
- ;
- Q
- ;
- POST ;EP - From KIDS.
- ;
- ; --- Restore dd audit settings.
- S %="AUDR^BMC4P1"
- I $$NEWCP^XPDUTL("POS1-"_%,%)
- ;
- ; --- Send mail message of install.
- S %="MAIL^BMC4P1"
- I $$NEWCP^XPDUTL("POS2-"_%,%)
- ;
- Q
- ;
- MAIL ;
- D BMES^XPDUTL("BEGIN Delivering MailMan message to select users.")
- NEW DIFROM,XMSUB,XMDUZ,XMTEXT,XMY
- KILL ^TMP("BMC4P1",$J)
- D RSLT(" --- BMC v 4.0 Patch 1, has been installed into this uci ---")
- F %=1:1 D RSLT($P($T(GREET+%),";",3)) Q:$P($T(GREET+%+1),";",3)="###"
- S %=0
- F S %=$O(^XTMP("XPDI",XPDA,"BLD",XPDBLD,1,%)) Q:'% D RSLT(^(%,0))
- S XMSUB=$P($P($T(+1),";",2)," ",3,99),XMDUZ=$S($G(DUZ):DUZ,1:.5),XMTEXT="^TMP(""BMC4P1"",$J,",XMY(1)="",XMY(DUZ)=""
- F %="BMCZMENU","XUMGR","XUPROG","XUPROGMODE" D SINGLE(%)
- D ^XMD
- KILL ^TMP("BMC4P1",$J)
- D MES^XPDUTL("END Delivering MailMan message to select users.")
- Q
- ;
- RSLT(%) S ^(0)=$G(^TMP("BMC4P1",$J,0))+1,^(^(0))=%
- Q
- ;
- SINGLE(K) ; Get holders of a single key K.
- NEW Y
- S Y=0
- Q:'$D(^XUSEC(K))
- F S Y=$O(^XUSEC(K,Y)) Q:'Y S XMY(Y)=""
- Q
- ;
- INTROE ; Intro text during KIDS Environment check.
- ;;In this distribution:
- ;;(1) General Retrieval Report:
- ;; a. Changed CHS PDO issue date to print in format xx/xx/xx
- ;; b. Added CHS Approval/Denial date to search, sort and print
- ;; c. Changed heading from Select screen to Search Screen
- ;;(2) Added following Major DX Category:
- ;; a. Skin and Subcutaneous Tissue
- ;; b. Complications of Pregnancy, Childbirth and the Puerperium
- ;;(3) Referral Facility Address
- ;; a. Address fields added to the Rcis Site Parameter file
- ;; b. If fields are not populated will default to Location file
- ;; c. Edit and Display Site parameter options were modified
- ;; d. All letters updated to use new address fields
- ;;(4) Case Management Reports:
- ;; a. Added total to Print Case Review Comments report
- ;; b. Added Report run date to the Inpatient Log Report
- ;; c. Added Date Range to the Area Discharge report
- ;; d. Added Date Range to the List of High Cost Users Report
- ;; e. Added Date Range to Potential High Cost Cases
- ;; f. Added Report Run Date to Patient Dish/Cons Sum not rec'd
- ;;(5) Trending reports now print in Alpha order for providers
- ;; a. Referral Patterns by Provider or Facility
- ;; b. CHS Referral Costs By Requesting Prov/Facility
- ;;(6) Display a Referral; when selecting by patient name will display
- ;; most recent referral entered
- ;;(7) Miscellaneous routine modifications
- ;; a. Fixed Entering final values when Closing referral
- ;; b. If Insurance data entered, but not the "insurance plan"
- ;; letter will error out, will now print 'unknown"
- ;; c. Sec Ref data entry; fixed space bar at prompt
- ;; d. Letters now printing elg and coverage for Medicaid/Medicare
- ;;###
- ;
- INTROI ; Intro text during KIDS Install.
- ;;A standard message will be produced by this update.
- ;;
- ;;If you run interactively, results will be displayed on your screen,
- ;;as well as in the mail message and the entry in the INSTALL file.
- ;;If you queue to TaskMan, please read the mail message for results of
- ;;this update, and remember not to Q to the HOME device.
- ;;###
- ;
- GREET ;;To add to mail message.
- ;;
- ;;Greetings.
- ;;
- ;;Standard data dictionaries on your RPMS system have been updated.
- ;;
- ;;You are receiving this message because of the particular RPMS
- ;;security keys that you hold. This is for your information, only.
- ;;You need do nothing in response to this message.
- ;;
- ;;Questions about this patch, which is a product of the RPMS DBA
- ;;,
- ;;can be directed to the Help Desk,
- ;;
- ;;Please refer to patch "bmc*4.0*1".
- ;;
- ;;###;NOTE: This line indicates the end of text in this message.
- ;
- ; -----------------------------------------------------
- ; The global location for dictionary audit is:
- ; ^DD(FILE,0,"DDA")
- ; If the valuey is "Y", dd audit is on. Any other value, or the
- ; absence of the node, means dd audit is off.
- ; -----------------------------------------------------
- AUDS ;EP - From KIDS.
- D BMES^XPDUTL("Saving current DD AUDIT settings for files in this patch")
- D MES^XPDUTL("and turning DD AUDIT to 'Y'.")
- S ^XTMP("BMC4P1",0)=$$FMADD^XLFDT(DT,10)_"^"_DT_"^"_$P($P($T(+1),";",2)," ",3,99)
- NEW BMC
- S BMC=0
- F S BMC=$O(^XTMP("XPDI",XPDA,"FIA",BMC)) Q:'BMC D
- . I '$D(^XTMP("BMC4P1",BMC,"DDA")) S ^XTMP("BMC4P1",BMC,"DDA")=$G(^DD(BMC,0,"DDA"))
- . D MES^XPDUTL(" File "_$$RJ^XLFSTR(BMC,12)_" - "_$$LJ^XLFSTR(^XTMP("XPDI",XPDA,"FIA",BMC),30)_"- DD audit was '"_$G(^XTMP("BMC4P1",BMC,"DDA"))_"'"),MES^XPDUTL($$RJ^XLFSTR("Set to 'Y'",69))
- . S ^DD(BMC,0,"DDA")="Y"
- .Q
- D MES^XPDUTL("DD AUDIT settings saved in ^XTMP(.")
- ;TEST FOR MIS SPELLED DX CATE DURING BETA TESTING
- I $D(^BMCTDXC("B","COMPLICATIONS FO PREGNANCY,CHI")) D
- .S DA=0,DA=$O(^BMCTDXC("B","COMPLICATIONS FO PREGNANCY,CHI",DA))
- .S DR=".01////COMPLICATIONS OF PREGNANCY,CHILDBIRTH AND PUERPERIUM"
- .S DIE="^BMCTDXC(" I DA D ^DIE
- .K D0,DA,DA,DIE,DR
- Q
- ; -----------------------------------------------------
- AUDR ; Restore the file data audit values to their original values.
- D BMES^XPDUTL("Restoring DD AUDIT settings for files in this patch.")
- NEW BMC
- S BMC=0
- F S BMC=$O(^XTMP("BMC4P1",BMC)) Q:'BMC D
- . S ^DD(BMC,0,"DDA")=^XTMP("BMC4P1",BMC,"DDA")
- . D MES^XPDUTL(" File "_$$RJ^XLFSTR(BMC,12)_" - "_$$LJ^XLFSTR($$GET1^DID(BMC,"","","NAME"),30)_"- DD AUDIT Set to '"_^DD(BMC,0,"DDA")_"'")
- .Q
- KILL ^XTMP("BMC4P1")
- D MES^XPDUTL("DD AUDIT settings restored.")
- Q
- ; -----------------------------------------------------
- ;
- INSTALLD(BMC) ; Determine if patch BMC was installed, where BMC is
- ; the name of the INSTALL. E.g "AVA*93.2*12".
- ;
- NEW DIC,X,Y
- ; lookup package.
- S X=$P(BMC,"*",1)
- S DIC="^DIC(9.4,",DIC(0)="FM",D="C"
- D IX^DIC
- I Y<1 Q 0
- ; lookup version.
- S DIC=DIC_+Y_",22,",X=$P(BMC,"*",2)
- D ^DIC
- I Y<1 Q 0
- ; lookup patch.
- S DIC=DIC_+Y_",""PAH"",",X=$P(BMC,"*",3)
- D ^DIC
- Q $S(Y<1:0,1:1)
- ;
- ; -----------------------------------------------------
- BMC4P1 ;IHS/ITSC/FCJ - BMC 4.0 PATCH 1 ; [ 06/02/2006 2:07 PM ]
- +1 ;;4.0;REFERRED CARE INFO SYSTEM;**1**;JUN 01, 2006
- +2 ;
- +3 ;
- +4 IF '$GET(IOM)
- DO HOME^%ZIS
- +5 ;
- +6 IF '$GET(DUZ)
- WRITE !,"DUZ UNDEFINED OR 0."
- DO SORRY(2)
- QUIT
- +7 ;
- +8 IF '$LENGTH($GET(DUZ(0)))
- WRITE !,"DUZ(0) UNDEFINED OR NULL."
- DO SORRY(2)
- QUIT
- +9 ;
- +10 IF '(DUZ(0)["@")
- IF '$DATA(ZTQUEUED)
- WRITE !,"DUZ(0) DOES NOT CONTAIN AN '@'."
- DO SORRY(2)
- QUIT
- +11 ;
- +12 SET X=$$GET1^DIQ(200,DUZ,.01)
- +13 WRITE !!,$$CJ^XLFSTR("Hello, "_$PIECE(X,",",2)_" "_$PIECE(X,","),IOM)
- +14 WRITE !!,$$CJ^XLFSTR("Checking Environment for "_$PIECE($TEXT(+2),";",4)_" V "_$PIECE($TEXT(+2),";",3)_".",IOM)
- +15 ;
- +16 NEW IORVON,IORVOFF
- +17 SET X="IORVON;IORVOFF"
- +18 DO ENDR^%ZISS
- +19 ;
- +20 IF $$VCHK("BMC","4.0",2,"'=")
- +21 IF $$VCHK("XU","8.0",2,"<")
- +22 IF $$VCHK("DI","21.0",2,"<")
- +23 IF $$VCHK("ATX","5.1",2,"<")
- +24 IF $$VCHK("AUPN","99.1",2,"<")
- +25 ;
- +26 NEW DA,DIC
- +27 SET X="BMC"
- SET DIC="^DIC(9.4,"
- SET DIC(0)=""
- SET D="C"
- +28 DO IX^DIC
- +29 IF Y<0
- IF $DATA(^DIC(9.4,"C","BMC"))
- Begin DoDot:1
- +30 WRITE !!,*7,*7,$$CJ^XLFSTR("You Have More Than One Entry In The",IOM),!,$$CJ^XLFSTR("PACKAGE File with an ""BMC"" prefix.",IOM)
- +31 WRITE !,$$CJ^XLFSTR(IORVON_"One entry needs to be deleted."_IORVOFF,IOM)
- +32 DO SORRY(2)
- End DoDot:1
- +33 ;
- +34 IF $GET(XPDQUIT)
- WRITE !,$$CJ^XLFSTR(IORVON_"FIX IT! Before Proceeding."_IORVOFF,IOM),!!,*7,*7,*7
- QUIT
- +35 ;
- +36 WRITE !!,$$CJ^XLFSTR("ENVIRONMENT OK.",IOM)
- +37 ;
- +38 DO HELP^XBHELP("INTROE","BMC4P1")
- +39 IF '$$DIR^XBDIR("E","","","","","",1)
- DO SORRY(2)
- QUIT
- +40 ;
- +41 IF $GET(XPDENV)=1
- SET (XPDDIQ("XPZ1"),XPDDIQ("XPZ2"))=0
- DO HELP^XBHELP("INTROI","BMC4P1")
- IF '$$DIR^XBDIR("E","","","","","",1)
- DO SORRY(2)
- +42 ;
- +43 QUIT
- +44 ;
- SORRY(X) ;
- +1 KILL DIFQ
- +2 SET XPDQUIT=X
- +3 WRITE *7,!,$$CJ^XLFSTR("Sorry....FIX IT!",IOM)
- +4 QUIT
- +5 ;
- VCHK(BMCPRE,BMCVER,BMCQUIT,BMCCOMP) ; Check versions needed.
- +1 ;
- +2 NEW BMCV
- +3 SET BMCV=$$VERSION^XPDUTL(BMCPRE)
- +4 WRITE !,$$CJ^XLFSTR("Need "_$SELECT(BMCCOMP="<":"at least ",1:"")_BMCPRE_" v "_BMCVER_"....."_BMCPRE_" v "_BMCV_" Present",IOM)
- +5 IF @(BMCV_BMCCOMP_BMCVER)
- DO SORRY(BMCQUIT)
- QUIT 0
- +6 QUIT 1
- +7 ;
- PRE ;EP - From KIDS.
- +1 IF $$NEWCP^XPDUTL("PRE1","AUDS^BMC4P1")
- +2 ; The following line prevents the "Disable Options..." and "Move
- +3 ; Routines..." questions from being asked during the install.
- +4 IF $GET(XPDENV)=1
- SET (XPDDIQ("XPZ1"),XPDDIQ("XPZ2"))=0
- +5 ;
- +6 QUIT
- +7 ;
- POST ;EP - From KIDS.
- +1 ;
- +2 ; --- Restore dd audit settings.
- +3 SET %="AUDR^BMC4P1"
- +4 IF $$NEWCP^XPDUTL("POS1-"_%,%)
- +5 ;
- +6 ; --- Send mail message of install.
- +7 SET %="MAIL^BMC4P1"
- +8 IF $$NEWCP^XPDUTL("POS2-"_%,%)
- +9 ;
- +10 QUIT
- +11 ;
- MAIL ;
- +1 DO BMES^XPDUTL("BEGIN Delivering MailMan message to select users.")
- +2 NEW DIFROM,XMSUB,XMDUZ,XMTEXT,XMY
- +3 KILL ^TMP("BMC4P1",$JOB)
- +4 DO RSLT(" --- BMC v 4.0 Patch 1, has been installed into this uci ---")
- +5 FOR %=1:1
- DO RSLT($PIECE($TEXT(GREET+%),";",3))
- IF $PIECE($TEXT(GREET+%+1),";",3)="###"
- QUIT
- +6 SET %=0
- +7 FOR
- SET %=$ORDER(^XTMP("XPDI",XPDA,"BLD",XPDBLD,1,%))
- IF '%
- QUIT
- DO RSLT(^(%,0))
- +8 SET XMSUB=$PIECE($PIECE($TEXT(+1),";",2)," ",3,99)
- SET XMDUZ=$SELECT($GET(DUZ):DUZ,1:.5)
- SET XMTEXT="^TMP(""BMC4P1"",$J,"
- SET XMY(1)=""
- SET XMY(DUZ)=""
- +9 FOR %="BMCZMENU","XUMGR","XUPROG","XUPROGMODE"
- DO SINGLE(%)
- +10 DO ^XMD
- +11 KILL ^TMP("BMC4P1",$JOB)
- +12 DO MES^XPDUTL("END Delivering MailMan message to select users.")
- +13 QUIT
- +14 ;
- RSLT(%) SET ^(0)=$GET(^TMP("BMC4P1",$JOB,0))+1
- SET ^(^(0))=%
- +1 QUIT
- +2 ;
- SINGLE(K) ; Get holders of a single key K.
- +1 NEW Y
- +2 SET Y=0
- +3 IF '$DATA(^XUSEC(K))
- QUIT
- +4 FOR
- SET Y=$ORDER(^XUSEC(K,Y))
- IF 'Y
- QUIT
- SET XMY(Y)=""
- +5 QUIT
- +6 ;
- INTROE ; Intro text during KIDS Environment check.
- +1 ;;In this distribution:
- +2 ;;(1) General Retrieval Report:
- +3 ;; a. Changed CHS PDO issue date to print in format xx/xx/xx
- +4 ;; b. Added CHS Approval/Denial date to search, sort and print
- +5 ;; c. Changed heading from Select screen to Search Screen
- +6 ;;(2) Added following Major DX Category:
- +7 ;; a. Skin and Subcutaneous Tissue
- +8 ;; b. Complications of Pregnancy, Childbirth and the Puerperium
- +9 ;;(3) Referral Facility Address
- +10 ;; a. Address fields added to the Rcis Site Parameter file
- +11 ;; b. If fields are not populated will default to Location file
- +12 ;; c. Edit and Display Site parameter options were modified
- +13 ;; d. All letters updated to use new address fields
- +14 ;;(4) Case Management Reports:
- +15 ;; a. Added total to Print Case Review Comments report
- +16 ;; b. Added Report run date to the Inpatient Log Report
- +17 ;; c. Added Date Range to the Area Discharge report
- +18 ;; d. Added Date Range to the List of High Cost Users Report
- +19 ;; e. Added Date Range to Potential High Cost Cases
- +20 ;; f. Added Report Run Date to Patient Dish/Cons Sum not rec'd
- +21 ;;(5) Trending reports now print in Alpha order for providers
- +22 ;; a. Referral Patterns by Provider or Facility
- +23 ;; b. CHS Referral Costs By Requesting Prov/Facility
- +24 ;;(6) Display a Referral; when selecting by patient name will display
- +25 ;; most recent referral entered
- +26 ;;(7) Miscellaneous routine modifications
- +27 ;; a. Fixed Entering final values when Closing referral
- +28 ;; b. If Insurance data entered, but not the "insurance plan"
- +29 ;; letter will error out, will now print 'unknown"
- +30 ;; c. Sec Ref data entry; fixed space bar at prompt
- +31 ;; d. Letters now printing elg and coverage for Medicaid/Medicare
- +32 ;;###
- +33 ;
- INTROI ; Intro text during KIDS Install.
- +1 ;;A standard message will be produced by this update.
- +2 ;;
- +3 ;;If you run interactively, results will be displayed on your screen,
- +4 ;;as well as in the mail message and the entry in the INSTALL file.
- +5 ;;If you queue to TaskMan, please read the mail message for results of
- +6 ;;this update, and remember not to Q to the HOME device.
- +7 ;;###
- +8 ;
- GREET ;;To add to mail message.
- +1 ;;
- +2 ;;Greetings.
- +3 ;;
- +4 ;;Standard data dictionaries on your RPMS system have been updated.
- +5 ;;
- +6 ;;You are receiving this message because of the particular RPMS
- +7 ;;security keys that you hold. This is for your information, only.
- +8 ;;You need do nothing in response to this message.
- +9 ;;
- +10 ;;Questions about this patch, which is a product of the RPMS DBA
- +11 ;;,
- +12 ;;can be directed to the Help Desk,
- +13 ;;
- +14 ;;Please refer to patch "bmc*4.0*1".
- +15 ;;
- +16 ;;###;NOTE: This line indicates the end of text in this message.
- +17 ;
- +18 ; -----------------------------------------------------
- +19 ; The global location for dictionary audit is:
- +20 ; ^DD(FILE,0,"DDA")
- +21 ; If the valuey is "Y", dd audit is on. Any other value, or the
- +22 ; absence of the node, means dd audit is off.
- +23 ; -----------------------------------------------------
- AUDS ;EP - From KIDS.
- +1 DO BMES^XPDUTL("Saving current DD AUDIT settings for files in this patch")
- +2 DO MES^XPDUTL("and turning DD AUDIT to 'Y'.")
- +3 SET ^XTMP("BMC4P1",0)=$$FMADD^XLFDT(DT,10)_"^"_DT_"^"_$PIECE($PIECE($TEXT(+1),";",2)," ",3,99)
- +4 NEW BMC
- +5 SET BMC=0
- +6 FOR
- SET BMC=$ORDER(^XTMP("XPDI",XPDA,"FIA",BMC))
- IF 'BMC
- QUIT
- Begin DoDot:1
- +7 IF '$DATA(^XTMP("BMC4P1",BMC,"DDA"))
- SET ^XTMP("BMC4P1",BMC,"DDA")=$GET(^DD(BMC,0,"DDA"))
- +8 DO MES^XPDUTL(" File "_$$RJ^XLFSTR(BMC,12)_" - "_$$LJ^XLFSTR(^XTMP("XPDI",XPDA,"FIA",BMC),30)_"- DD audit was '"_$GET(^XTMP("BMC4P1",BMC,"DDA"))_"'")
- DO MES^XPDUTL($$RJ^XLFSTR("Set to 'Y'",69))
- +9 SET ^DD(BMC,0,"DDA")="Y"
- +10 QUIT
- End DoDot:1
- +11 DO MES^XPDUTL("DD AUDIT settings saved in ^XTMP(.")
- +12 ;TEST FOR MIS SPELLED DX CATE DURING BETA TESTING
- +13 IF $DATA(^BMCTDXC("B","COMPLICATIONS FO PREGNANCY,CHI"))
- Begin DoDot:1
- +14 SET DA=0
- SET DA=$ORDER(^BMCTDXC("B","COMPLICATIONS FO PREGNANCY,CHI",DA))
- +15 SET DR=".01////COMPLICATIONS OF PREGNANCY,CHILDBIRTH AND PUERPERIUM"
- +16 SET DIE="^BMCTDXC("
- IF DA
- DO ^DIE
- +17 KILL D0,DA,DA,DIE,DR
- End DoDot:1
- +18 QUIT
- +19 ; -----------------------------------------------------
- AUDR ; Restore the file data audit values to their original values.
- +1 DO BMES^XPDUTL("Restoring DD AUDIT settings for files in this patch.")
- +2 NEW BMC
- +3 SET BMC=0
- +4 FOR
- SET BMC=$ORDER(^XTMP("BMC4P1",BMC))
- IF 'BMC
- QUIT
- Begin DoDot:1
- +5 SET ^DD(BMC,0,"DDA")=^XTMP("BMC4P1",BMC,"DDA")
- +6 DO MES^XPDUTL(" File "_$$RJ^XLFSTR(BMC,12)_" - "_$$LJ^XLFSTR($$GET1^DID(BMC,"","","NAME"),30)_"- DD AUDIT Set to '"_^DD(BMC,0,"DDA")_"'")
- +7 QUIT
- End DoDot:1
- +8 KILL ^XTMP("BMC4P1")
- +9 DO MES^XPDUTL("DD AUDIT settings restored.")
- +10 QUIT
- +11 ; -----------------------------------------------------
- +12 ;
- INSTALLD(BMC) ; Determine if patch BMC was installed, where BMC is
- +1 ; the name of the INSTALL. E.g "AVA*93.2*12".
- +2 ;
- +3 NEW DIC,X,Y
- +4 ; lookup package.
- +5 SET X=$PIECE(BMC,"*",1)
- +6 SET DIC="^DIC(9.4,"
- SET DIC(0)="FM"
- SET D="C"
- +7 DO IX^DIC
- +8 IF Y<1
- QUIT 0
- +9 ; lookup version.
- +10 SET DIC=DIC_+Y_",22,"
- SET X=$PIECE(BMC,"*",2)
- +11 DO ^DIC
- +12 IF Y<1
- QUIT 0
- +13 ; lookup patch.
- +14 SET DIC=DIC_+Y_",""PAH"","
- SET X=$PIECE(BMC,"*",3)
- +15 DO ^DIC
- +16 QUIT $SELECT(Y<1:0,1:1)
- +17 ;
- +18 ; -----------------------------------------------------