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

AUM16P3.m

Go to the documentation of this file.
  1. AUM16P3 ;IHS/OIT/NKD - SCB UPDATE V16 P3 POST-INSTALL 07/05/2016 ;
  1. ;;16.0;TABLE MAINTENANCE;**3**;OCT 16,2015;Build 1
  1. ;
  1. ;
  1. ;
  1. POST ; EP FR KIDS - RUN KIDS POST-INSTALL
  1. D S1
  1. D S2
  1. D POST^AUMSCB
  1. Q
  1. ;
  1. S1 ; SCAN FOR WP NODES WITH LENGTH >80 IN THE HELP TEXT FIELD OF THE MEASUREMENT TYPE FILE
  1. N AUMI,AUMSN,AUMCNT,CHK,AUMWPFR,AUMWPTO
  1. D RSLT^AUMSCBD($$REPEAT^XLFSTR("-",20)),RSLT^AUMSCBD("AUM*16.0*3 Measurement Type help text cleanup")
  1. S (AUMI,AUMCNT)=0 F S AUMI=$O(^AUTTMSR(AUMI)) Q:'AUMI D
  1. . S (AUMSN,CHK)=0 F S AUMSN=$O(^AUTTMSR(AUMI,11,AUMSN)) Q:'AUMSN!CHK S:$L($G(^AUTTMSR(AUMI,11,AUMSN,0)))>80 CHK=1
  1. . Q:'CHK
  1. . S AUMWPFR=$$GET1^DIQ(9999999.07,AUMI,1100,,"AUMWPFR"),AUMCNT=AUMCNT+1
  1. . S AUMSN=0 F S AUMSN=$O(AUMWPFR(AUMSN)) Q:'AUMSN S AUMWPTO=$G(AUMWPTO)_$S(AUMSN>1:"|",1:"")_$G(AUMWPFR(AUMSN))
  1. . D TEXT^AUMSCBD(.AUMWPTO),WP^DIE(9999999.07,AUMI_",",1100,,"AUMWPTO")
  1. . W "."
  1. D RSLT^AUMSCBD("Formatting corrections made to "_AUMCNT_" WP fields.")
  1. Q
  1. ;
  1. S2 ; SCAN FOR DUPLICATE HEALTH FACTOR NAMES AND APPLY NEW FORMAT TO INACTIVE ENTRIES
  1. N AUMN,AUMI,AUMINA,AUMCNT,AUMFDA,AUM0,AUMP
  1. D RSLT^AUMSCBD($$REPEAT^XLFSTR("-",20)),RSLT^AUMSCBD("AUM*16.0*3 Duplicate Health Factor cleanup")
  1. S AUMCNT=0,AUMN="" F S AUMN=$O(^AUTTHF("B",AUMN)) Q:'$L(AUMN) D
  1. . S AUMI=0 F S AUMI=$O(^AUTTHF("B",AUMN,AUMI)) Q:'AUMI D
  1. . . Q:'$O(^AUTTHF("B",AUMN,AUMI))&'$O(^AUTTHF("B",AUMN,AUMI),-1)
  1. . . S AUM0=$G(^AUTTHF(AUMI,0)) Q:'$L(AUM0) Q:'$P(AUM0,U,13)
  1. . . S AUMP=$S($P(AUM0,U,10)="C":"y",1:"z") Q:$E($P(AUM0,U))=AUMP!($E($P(AUM0,U,2))=AUMP)
  1. . . S AUMCNT=AUMCNT+1
  1. . . S AUMFDA(9999999.64,AUMI_",",.01)=$E(AUMP_AUMP_$P(AUM0,U),1,40)
  1. . . S AUMFDA(9999999.64,AUMI_",",.02)=AUMP_$E($P(AUM0,U,2),2,4)
  1. I $D(AUMFDA) D FILE^DIE(,"AUMFDA")
  1. D RSLT^AUMSCBD("Inactive formatting applied to "_AUMCNT_" duplicate entries.")
  1. Q
  1. ;