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

ABMDTFEE.m

Go to the documentation of this file.
ABMDTFEE ; IHS/SD/SDR - Table Maintenance of 3P CODES ;
 ;;2.6;IHS Third Party Billing;**1,2,21,27**;NOV 12, 2009;Build 486
 ;
 ;IHS/SD/SDR 2.6 CSV
 ;IHS/SD/SDR 2.6*1 NO HEAT - Populate owner of table
 ;IHS/SD/SDR 2.6*2 3PMS10003A - populate new effective dates multiple
 ;IHS/SD/SDR 2.6*21 HEAT135354 Fix so when CPT selected the effective fee, if there is one, will display; was just printing a dash, no description, and 0.00 for the fee no matter what was entered.
 ;IHS/SD/SDR 2.6*27 CR8894 Fixed so short descriptions and fees will print if ?? typed at any prompt.  Fixed how entries were getting filed to use new
 ;  DINUM methodology.  It requires codes to be hardset into global and then edited.
 ;
 S U="^" W !
FEE K DIC
 S DIC="^ABMDFEE(",DIC(0)="QEAML"
 S DIC("A")="Select FEE SCHEDULE: "
 S:$P($G(^ABMDPARM(DUZ(2),1,0)),U,9)]"" DIC("B")=$P(^(0),U,9)
 S DIC("S")="I DUZ(2)=$P($G(^ABMDFEE(X,0)),""^"",4)"
 ;S DIC("DR")=".02;.04////"_DUZ(2)  ;abm*2.6*1 NO HEAT  ;abm*2.6*27 IHS/SD/SDR CR8894
 S DIC("DR")=".02;.06////C;.04////"_DUZ(2)  ;abm*2.6*1 NO HEAT  ;abm*2.6*27 IHS/SD/SDR CR8894
 D ^DIC
 G XIT:$D(DUOUT)!$D(DTOUT)
 I +Y<1 G FEE
 S ABM("FEE")=+Y
SEL W !!,"----- FEE SCHEDULE CATEGORIES -----",!
 S DIR(0)="SO^1:MEDICAL FEES;2:SURGICAL FEES;3:RADIOLOGY FEES;4:LABORATORY FEES;5:ANESTHESIA FEES;6:DENTAL FEES;7:REVENUE CODE;8:HCPCS FEES;9:DRUG FEES;10:CHARGE MASTER"
 S DIR("A")="Select Desired CATEGORY"
 D ^DIR K DIR
 G XIT:$D(DIROUT)!$D(DIRUT)
 S ABM=+Y
 ;
 S ABM("SUB")=$S(ABM=1:19,ABM=2:11,ABM=3:15,ABM=4:17,ABM=5:23,ABM=6:21,ABM=7:31,ABM=8:13,ABM=9:25,ABM=10:32)
EDIT ;
 ;start old abm*2.6*27 IHS/SD/SDR CR8894
 ;K DIC  ;abm*2.6*2 3PMS10003A moved EDIT tag to here
 ;S DA(1)=ABM("FEE")
 ;;S (DIC,DIE)="^ABMDFEE("_DA(1)_","_ABM("SUB")_","  ;abm*2.6*2 3PMS10003A
 ;S DIC="^ABMDFEE("_DA(1)_","_ABM("SUB")_","  ;abm*2.6*2 3PMS10003A
 ;S:'$D(@(DIC_"0)")) @(DIC_"0)")="^9002274.01"_ABM("SUB")_"P"
 ;S ABM("DICS")=9002274.01_ABM("SUB") X:$D(^DD(ABM("DICS"),.01,12.1)) ^DD(ABM("DICS"),.01,12.1)
 ;;start old code abm*2.6*2 3PMS10003A
 ;;I ABM=7 S DIC("W")="W "" - "",$P($G(^AUTTREVN(Y,0)),U,2),?65,$J($FN($P($G(^ABMDFEE(DA(1),31,Y,0)),U,2),"","",2),9)"
 ;;I ABM=6 S DIC("W")="W "" - "",$P($G(^AUTTADA(Y,0)),U,2),?65,$J($FN($P($G(^ABMDFEE(DA(1),21,Y,0)),U,2),"","",2),9)"
 ;;I "123458"[ABM S DIC("W")="W "" - "",$P($$CPT^ABMCVAPI(Y,DT),U,3),?65,$J($FN($P($G(^ABMDFEE(DA(1),ABM(""SUB""),Y,0)),U,2),"","",2),9)"  ;CSV-c
 ;;S DR=".02"
 ;;end old code start new code 3PMS10003A
 ;I ABM=7 S DIC("W")="W "" - "",$P($G(^AUTTREVN(Y,0)),U,2),?65,$J($FN($P($$ONE^ABMFEAPI(DA(1),31,Y,DT),U),"","",2),9)"
 ;;I ABM=6 S DIC("W")="W "" - "",$P($G(^AUTTADA(Y,0)),U,2),?65,$J($FN($P($$ONE^ABMFEAPI(DA(1),21,Y,DT),U),"","",2),9)"  ;abm*2.6*27 IHS/SD/SDR CR8894
 ;I ABM=6 S DIC("W")="S ABMR(""CODE"")=$E(Y,2,5) W "" - "",$E($P($G(^AUTTADA($P(^ABMDFEE(DA(1),21,Y,0),U),0)),U,2),1,45),?65,$J($FN($P($$ONE^ABMFEAPI(DA(1),21,Y,DT),U),"","",2),9)"  ;abm*2.6*27 IHS/SD/SDR CR8894
 ;;I "123458"[ABM S DIC("W")="W "" - "",$P($$CPT^ABMCVAPI(Y,DT),U,3),?65,$J($FN($P($$ONE^ABMFEAPI(DA(1),ABM(""SUB""),Y,DT),U),"","",2),9)"  ;CSV-c  ;abm*2.6*21 IHS/SD/SDR HEAT135354
 ;;I "123458"[ABM S DIC("W")="W "" - "",$P($$CPT^ABMCVAPI(X,DT),U,3),?65,$J($FN($P($$ONE^ABMFEAPI(DA(1),ABM(""SUB""),$P($$CPT^ABMCVAPI(X,DT),U),DT),U),"","",2),9)"  ;CSV-c  ;abm*2.6*21 IHS/SD/SDR HEAT135354  ;abm*2.6*27 IHS/SD/SDR CR8894
 ;;start new abm*2.6*27 IHS/SD/SDR CR8894
 ;I "123458"[ABM D
 ;.S DIC("W")=" W "" - "",$P($$CPT^ABMCVAPI(Y,DT),U,3),?65,$J($FN($P($$ONE^ABMFEAPI(DA(1),ABM(""SUB""),$P($$CPT^ABMCVAPI(Y,DT),U),DT),U),"","",2),9)"
 ;I ABM=9 S DIC("W")="W ?50,$P($G(^PSDRUG(Y,2)),U,4),?65,$J($FN($P($$ONE^ABMFEAPI(DA(1),ABM(""SUB""),Y,DT),U),"","",2),9)"
 ;I ABM=10 S DIC("W")="W ?65,$J($FN($P($$ONE^ABMFEAPI(DA(1),ABM(""SUB""),Y,DT),U),"","",2),9)"
 ;;end new abm*2.6*27 IHS/SD/SDR CR8894
 ;;end new code 3PMS10003A
 ;;
 ;W !!  ;abm*2.6*2 3PMS10003A removed EDIT tag from here
 ;S DIC(0)="QLEAM"
 ;D ^DIC K DIC
 ;
 ;end old start new abm*2.6*27 IHS/SD/SDR CR8894
 ;
 K DIC  ;abm*2.6*2 3PMS10003A moved EDIT tag to here
 S DIC="^ICPT("
 I "^6^7^9^10^"[("^"_ABM_"^") D
 .S DA(1)=ABM("FEE")
 .S DIC="^ABMDFEE("_DA(1)_","_ABM("SUB")_","
 .I ABM=7 S DIC("W")="W "" - "",$P($G(^AUTTREVN(Y,0)),U,2),?65,$J($FN($P($$ONE^ABMFEAPI(DA(1),31,Y,DT),U),"","",2),9)"
 .I ABM=6 S DIC("W")="S ABMR(""CODE"")=$E(Y,2,5) W "" - "",$E($P($G(^AUTTADA($P(^ABMDFEE(DA(1),21,Y,0),U),0)),U,2),1,45),?65,$J($FN($P($$ONE^ABMFEAPI(DA(1),21,Y,DT),U),"","",2),9)"
 .I ABM=9 S DIC("W")="W ?50,$P($G(^PSDRUG(Y,2)),U,4),?65,$J($FN($P($$ONE^ABMFEAPI(DA(1),ABM(""SUB""),Y,DT),U),"","",2),9)"
 .I ABM=10 S DIC("W")="W ?65,$J($FN($P($$ONE^ABMFEAPI(DA(1),ABM(""SUB""),Y,DT),U),"","",2),9)"
 ;
 S:'$D(@(DIC_"0)")) @(DIC_"0)")="^9002274.01"_ABM("SUB")_"P"
 S ABM("DICS")=9002274.01_ABM("SUB") X:$D(^DD(ABM("DICS"),.01,12.1)) ^DD(ABM("DICS"),.01,12.1)
 ;
 W !!
 S DIC(0)="QEAMI"
 I "^6^7^9^10^"[("^"_ABM_"^") S DIC(0)="QLEAM"
 D ^DIC K DIC
 ;end new abm*2.6*27 IHS/SD/SDR CR8894
 ;
 G SEL:X=""!$D(DUOUT)!$D(DTOUT)
 ;
 ;start new abm*2.6*27 IHS/SD/SDR CR8894
 I "123458"[(ABM) D
 .S X=$TR(X," ")
 .S ABMCODE=$$DINUM^ABMFOFS($P(Y,U,2))
 .I '$D(^ABMDFEE(ABM("FEE"),ABM("SUB"),ABMCODE)) D
 ..S ^ABMDFEE(ABM("FEE"),ABM("SUB"),ABMCODE,0)=+Y
 ..S ^ABMDFEE(ABM("FEE"),ABM("SUB"),"C",ABMCODE,+Y)=""
 ..S ^ABMDFEE(ABM("FEE"),ABM("SUB"),"B",+Y,ABMCODE)=""
 ;
 I "123458"[ABM D
 .;W !,ABMCODE," - ",$E($P($$CPT^ABMCVAPI(+Y,DT),U,3),1,55),?65,$J($FN($P($$ONE^ABMFEAPI(ABM("FEE"),ABM("SUB"),+Y,DT),U),",",2),9)
 .W !,X," - ",$E($P($$CPT^ABMCVAPI(+Y,DT),U,3),1,55),?65,$J($FN($P($$ONE^ABMFEAPI(ABM("FEE"),ABM("SUB"),+Y,DT),U),",",2),9)
 ;end new abm*2.6*27 IHS/SD/SDR CR8894
 ;
 I +Y<1 G EDIT
 ;start old code 3PMS10003A
 ;S DA=+Y
 ;S ABM("LDATE")=$P(^ABMDFEE(DA(1),ABM("SUB"),DA,0),U,3)
 ;S:ABM("SUB")=21 ABM("LDATE")=$P(^(0),U,4)
 ;I ABM("LDATE") W !,"Last Updated: ",$$SDT^ABMDUTL(ABM("LDATE"))
 ;end old code start new code 3PMS10003A
EFFDT ;
 ;S ABMCODE=+Y  ;abm*2.6*27 IHS/SD/SDR CR8894
 I "^6^7^9^10^"[("^"_ABM_"^") S ABMCODE=+Y  ;abm*2.6*27 IHS/SD/SDR CR8894
 D ^XBFMK
 S DA(2)=ABM("FEE")
 S DA(1)=ABMCODE
 S DIC="^ABMDFEE("_DA(2)_","_ABM("SUB")_","_DA(1)_",1,"
 S DIC(0)="AELQ"
 S DIC("P")=$P(^DD(9002274.01_ABM("SUB"),1,0),U,2)
 D ^DIC
 I $D(DTOUT)!$D(DUOUT) G EDIT  ;abm*2.6*2
 I Y<0 W "??  EFFECTIVE DATE REQUIRED" G EFFDT  ;abm*2.6*2
 S ABMENTRY=+Y
 D ^XBFMK
 S DA(2)=ABM("FEE")
 S DA(1)=ABMCODE
 S DIE="^ABMDFEE("_DA(2)_","_ABM("SUB")_","_DA(1)_",1,"
 S DA=ABMENTRY
 S DR=".02//"_$P($$ONE^ABMFEAPI(DA(2),ABM("SUB"),ABMCODE,DT),U)
 ;start old abm*2.6*27 IHS/SD/SDR CR8894
 ;S DR=DR_";.03//"_$P($$ONE^ABMFEAPI(DA(2),ABM("SUB"),ABMCODE,DT),U,2)
 ;S DR=DR_";.04//"_$P($$ONE^ABMFEAPI(DA(2),ABM("SUB"),ABMCODE,DT),U,3)
 ;end old start new abm*2.6*27 IHS/SD/SDR CR8894
 S DR=DR_";.03//"_+$P($$ONE^ABMFEAPI(DA(2),ABM("SUB"),ABMCODE,DT),U,2)
 S DR=DR_";.04//"_+$P($$ONE^ABMFEAPI(DA(2),ABM("SUB"),ABMCODE,DT),U,3)
 ;end new abm*2.6*27 IHS/SD/SDR CR8894
 S DR=DR_";.05////"_DT_";.06////"_DUZ
 ;end new code 3PMS10003A
 W !
 D ^ABMDDIE
 ;start new code abm*2.6*2 3PMS10003A
 D ^XBFMK
 S DA(1)=ABM("FEE")
 S DIE="^ABMDFEE("_DA(1)_","_ABM("SUB")_","
 S DA=ABMCODE
 S DR=".02////"_$P($$ONE^ABMFEAPI(ABM("FEE"),ABM("SUB"),ABMCODE,DT),U)
 D ^DIE
 ;this next part populates the UPDATE multiple
 D ^XBFMK
 S DA(1)=ABM("FEE")
 S DIC="^ABMDFEE("_DA(1)_",1,"
 S DIC(0)="MQL"
 S DIC("P")=$P(^DD(9002274.01,1,0),U,2)
 D NOW^%DTC
 S X=%
 S DIC("DR")=".02////"_DUZ
 D ^DIC
 ;end new code 3PMS10003A
 ;start new abm*2.6*27 IHS/SD/SDR CR8894
 S DA(1)=ABM("FEE")
 S DA=ABMCODE
 S DIK="^ABMDFEE("_DA(1)_","_ABM("SUB")_","
 D IX^DIK
 ;end new abm*2.6*27 IHS/SD/SDR CR8894
 G EDIT
 ;
XIT K ABM,DIR,DIC,DIE
 Q