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

IB20P384.m

Go to the documentation of this file.
  1. IB20P384 ;ALB/BDB - IB*2.0*384 POST INIT: ADD REASON NOT BILLABLE ;08-NOV-2007
  1. ;;2.0;INTEGRATED BILLING;**384**;21-MAR-94;Build 74
  1. ;;Per VHA Directive 2004-038, this routine should not be modified.
  1. ;
  1. Q
  1. ;
  1. POST ;
  1. N IBA
  1. S IBA(1)="",IBA(2)=" IB*2*384 Post-Install .....",IBA(3)="" D MES^XPDUTL(.IBA) K IBA
  1. D SCREEN7 ; Recompile the Screen 7 input template
  1. D SCEIEDIT ; Edit SCEI's to be ECME selectable in Claims Tracking Non-Billable Reasons file(#356.8)
  1. D IBERRAD ; New IB328 'ROI form required for sensitive record' IB Error file (#350.8)
  1. ;populate new #350.9 field #11.02 and add one record with reject code=70 to the subfile #350.912
  1. ;for NON-COVERED DRUGS functionality; add new non-billable reason "NON COVERED DRUG PER PLAN"
  1. D NONCOVDR
  1. D NEWR ; add new RNB to CT RNB file (#356.8)
  1. S IBA(1)="",IBA(2)=" IB*2*384 Post-Install Complete",IBA(3)="" D MES^XPDUTL(.IBA) K IBA
  1. Q
  1. ;
  1. SCEIEDIT ; Edit SCEI's to be ECME selectable in Claims Tracking Non-Billable Reasons file(#356.8)
  1. N DD,DO,DLAYGO,DINUM,DIC,DIE,DA,DR,X,Y,IBA,IBFOUND,IBFOUND1,IBATFN,IBNUM,IBAT,IBFN,IBIEN
  1. S IBA(1)="",IBA(2)=" >> Editing Service Connected/Environmental Indicators to be ECME"
  1. S IBA(3)=" >> selectable in the Claims Tracking Non-Billable Reasons file (#356.8)"
  1. S IBFOUND1=""
  1. F IBNUM=1:1:8 S IBIEN=$O(^IBE(356.8,"B",$P("SC TREATMENT^AGENT ORANGE^IONIZING RADIATION^SOUTHWEST ASIA^MILITARY SEXUAL TRAUMA^HEAD/NECK CANCER^COMBAT VETERAN^PROJECT 112/SHAD",U,IBNUM),"")) D
  1. .S IBFOUND="" I +IBIEN S IBFOUND=$G(^IBE(356.8,IBIEN,0))
  1. .I IBFOUND="" S IBFOUND1=1 D MSG(" "),MSG(" *** ERROR: Entry "_$P("SC^AO^IR^SWA^MST^HNC^CV^SHAD",U,IBNUM)_" missing, could not edit") Q
  1. .S DR=".02////1;.03////0"
  1. .S DIE="^IBE(356.8,",DA=IBIEN D ^DIE K DIE,DA,DR,X,Y
  1. D:IBFOUND1="" MSG(" Done. Service Connected/Environmental Indicators edited")
  1. D:'(IBFOUND1="") MSG(" *** ERROR: One or more entries could not be edited")
  1. SCEIQ D MES^XPDUTL(.IBA) K IBA
  1. Q
  1. ;
  1. IBERRAD ; New IB328 'ROI form required for sensitive record' IB Error file (#350.8)
  1. N DD,DO,DINUM,DIC,DIE,DA,DR,X,Y,IBA,IBFOUND,IBATFN,IBAT,IBIEN
  1. S IBA(1)=" >> Adding IB328 'ROI form required for sensitive record'"
  1. S IBA(2)=" >> in the IB Error file (#350.8)"
  1. S IBAT="IB328",IBIEN=$G(^IBE(350.8,"AC",IBAT))
  1. S IBFOUND="" I +IBIEN S IBFOUND=$G(^IBE(350.8,IBIEN,0))
  1. I IBFOUND="IB328^ROI form required for sensitive record^IB328^1^3" D MSG(" Done. IB328 'ROI form required for sensitive record' already exists") G IBERRADQ
  1. I IBFOUND'="" D MSG(" "),MSG(" *** ERROR: Entry already exists, could not add") G IBERRADQ
  1. K DD,DO S DIC="^IBE(350.8,",DIC(0)="L",X=IBAT D FILE^DICN K DIC S IBIEN=+Y
  1. I Y<1 K X,Y D MSG(" "),MSG(" *** ERROR: New entry could not be added") G IBERRADQ
  1. S DR=".02////ROI form required for sensitive record;.03////IB328;.04////1;.05////3"
  1. S DIE="^IBE(350.8,",DA=+IBIEN D ^DIE K DIE,DA,DR,X,Y
  1. D MSG(" Done. IB328 'ROI form required for sensitive record' added")
  1. IBERRADQ D MES^XPDUTL(.IBA) K IBA
  1. Q
  1. ;
  1. MSG(X) ;
  1. N IBX S IBX=$O(IBA(999999),-1) S:'IBX IBX=1 S IBX=IBX+1
  1. S IBA(IBX)=$G(X)
  1. Q
  1. ;
  1. ;populate fields for NON-COVERED DRUGS functionality
  1. NONCOVDR ;
  1. I $P($G(^IBE(350.9,1,11)),U,2)>0 D Q
  1. . D BMES^XPDUTL(" >> Skipping: NON-COVERED DRUGS functionality has been already activated")
  1. N IBZZ,IBNREC
  1. D BMES^XPDUTL(" >> Populating new #350.9 fields for NON-COVERED DRUGS functionality")
  1. D BMES^XPDUTL(" >> turning off the NON-COVERED DRUGS functionality by default")
  1. S IBZZ=$$FILLFLDS^IBNCPUT1(350.9,11.02,1,0)
  1. I IBZZ'>0 D BMES^XPDUTL(" *** ERROR: "_$P(IBZZ,U,3))
  1. I '$O(^IBE(350.9,1,12,"B","70",0)) D
  1. . D BMES^XPDUTL(" >> adding '70 Product/Service Not Covered' as default reject code")
  1. . I $$INSITEM^IBNCPUT1(350.912,1,"70","","E")'>0 D BMES^XPDUTL(" *** ERROR: could not add")
  1. ;add a new non-billable reason "NON COVERED DRUG PER PLAN"
  1. ;to the file (#356.8) CLAIMS TRACKING NON-BILLABLE REASONS file
  1. I '$O(^IBE(356.8,"B","NON COVERED DRUG PER PLAN",0)) D
  1. . D BMES^XPDUTL(" >> adding a new 'NON COVERED DRUG PER PLAN' non-billable reason to the file #356.8")
  1. . S IBNREC=$$INSITEM^IBNCPUT1(356.8,"","NON COVERED DRUG PER PLAN","","E") I IBZZ'>0 D BMES^XPDUTL(" *** ERROR: could not add") Q
  1. . D BMES^XPDUTL(" >> setting the ECME FLAG to 'Yes'")
  1. . S IBZZ=$$FILLFLDS^IBNCPUT1(356.8,.02,+IBNREC,1) I IBZZ'>0 D BMES^XPDUTL(" *** ERROR: "_$P(IBZZ,U,3))
  1. . D BMES^XPDUTL(" >> setting the ECME PAPER FLAG to 'No'")
  1. . S IBZZ=$$FILLFLDS^IBNCPUT1(356.8,.03,+IBNREC,0) I IBZZ'>0 D BMES^XPDUTL(" *** ERROR: "_$P(IBZZ,U,3))
  1. Q
  1. ;
  1. SCREEN7 ;Recompile Screen 7 Input Template
  1. N DMAX,IBIEN,IBRTN,X,Y
  1. S DMAX=$$ROUSIZE^DILF
  1. D MES^XPDUTL("Recompiling Screen 7 input template ...")
  1. ;
  1. ;find the ien of the input template
  1. S IBIEN=$O(^DIE("B","IB SCREEN7",0)) Q:'IBIEN
  1. ;
  1. ;quit if input template not compiled
  1. S IBRTN=$P($G(^DIE(IBIEN,"ROUOLD")),U) Q:IBRTN=""
  1. ;
  1. D MES^XPDUTL("Compiling IB SCREEN7, compiled routine is "_IBRTN_" ...")
  1. S X=IBRTN,Y=IBIEN
  1. D EN^DIEZ
  1. D MES^XPDUTL("Completed compiling input template.")
  1. D MES^XPDUTL("")
  1. Q
  1. ;
  1. NEWR ; Add new RNBs (if RNB already exists ensure Code is set)
  1. N IBI,IBJ,IBLN,IBNM,IBRNB,IBTOT,IBTNC,IBTCH,DIC,DR,DO,X,Y,DLAYGO,DINUM,IBA
  1. S (IBTOT,IBTNC,IBTCH)=0 S DLAYGO=356.8
  1. ;
  1. D MSG(" Add 1 New Reason Not Billable (#356.8)...")
  1. ;
  1. F IBI=1:1 S IBLN=$P($T(NEW+IBI),";;",2,999) Q:'IBLN D
  1. . S IBNM=$P(IBLN,U,6) S IBRNB=$O(^IBE(356.8,"B",IBNM,0))
  1. . I IBRNB Q
  1. . ;
  1. . F IBJ=61:1 I '$D(^IBE(356.8,IBJ,0)),IBJ'=72,IBJ'=90 Q
  1. . ;
  1. . S IBTOT=IBTOT+1
  1. . ;
  1. . S DIC("DR")=".02////"_$P(IBLN,U,4)_";.03////"_$P(IBLN,U,5)
  1. . S DIC="^IBE(356.8,",DIC(0)="L",X=IBNM,DINUM=IBJ D FILE^DICN K DIC I 'Y D MSG(IBNM_" Not Added, ERROR ****") Q
  1. . S IBTCH=IBTCH+1 D MSG(" - "_IBNM_" added")
  1. ;
  1. I 'IBTCH D MSG(" No Change: "_IBTNC_" of "_IBTOT_" New RNBs Already Exist")
  1. I +IBTCH D MSG(" Updated: "_IBTCH_" of "_IBTOT_" New RNBs Added")
  1. ;
  1. D MES^XPDUTL(.IBA)
  1. ;
  1. Q
  1. ;
  1. ; RNB'S to add to CT RNB file
  1. NEW ;;
  1. ;;61^NEW^CV15^1^0^NO PHARMACY COVERAGE
  1. ;;
  1. Q