ABSPOSMI ; IHS/SD/RLT - POS Claims not Passed to 3PB ; [ 09/18/07 02:00 PM ]
;;1.0;PHARMACY POINT OF SALE;**22,28**;SEP 18, 2007;Build 38
;----------------------------------------------------------
;IHS/OIT/SCR - 09/24/08 patch 28 - commented out to remove HOLD functionality introduced
; by patch 22
;----------------------------------------------------------
Q
;----------------------------------------------------------
;
;EN ;EP
;
;K ^TMP("ABSPOSMI",$J)
;W @IOF
;W "Count of POS Claims not Passed to 3PB by Insurer",!
;W !
;N POP D ^%ZIS Q:$G(POP)
;D GETDATA
;U IO
;D DISDATA
;D ^%ZISC
;K ^TMP("ABSPOSMI",$J)
;Q
;
;GETDATA ;
;N ABSPLOG,ABSPTYPE,ABSPIIEN,ABSPINS
;S ABSPLOG=0
;F S ABSPLOG=$O(^ABSPHOLD(ABSPLOG)) Q:'+ABSPLOG D
;. S ABSPTYPE=$P($G(^ABSPHOLD(ABSPLOG,0)),U,2)
;. S ABSPIIEN=""
;. I ABSPTYPE="P" S ABSPIIEN=$P($G(^ABSPHOLD(ABSPLOG,"P")),U,8)
;. I ABSPTYPE="R" S ABSPIIEN=$P($G(^ABSPHOLD(ABSPLOG,"R")),U,3)
;. Q:ABSPIIEN=""
;. S ABSPINS=$$GET1^DIQ(9999999.18,ABSPIIEN_",",.01) ;name
;. S $P(^TMP("ABSPOSMI",$J,ABSPINS,ABSPIIEN),U)=+$P($G(^TMP("ABSPOSMI",$J,ABSPINS,ABSPIIEN)),U)+1
;. S $P(^TMP("ABSPOSMI",$J,"ZZZTOTAL",1),U)=+$P($G(^TMP("ABSPOSMI",$J,"ZZZTOTAL",1)),U)+1
;Q
;DISDATA ;
;N DASHES
;S $P(DASHES,"-",81)=""
;N ABSPINS,ABSPIIEN,ABSPICNT
;D HEADING
;I '$D(^TMP("ABSPOSMI",$J)) D Q
;. W !,"No held 3PB claims found!"
;. D ENDRPT^ABSPOSU5()
;S ABSPINS=""
;F S ABSPINS=$O(^TMP("ABSPOSMI",$J,ABSPINS)) Q:ABSPINS="" D
;. S ABSPIIEN=0
;. F S ABSPIIEN=$O(^TMP("ABSPOSMI",$J,ABSPINS,ABSPIIEN)) Q:'+ABSPIIEN D
;.. S ABSPICNT=$G(^TMP("ABSPOSMI",$J,ABSPINS,ABSPIIEN))
;.. I ABSPINS="ZZZTOTAL" D
;... W !,?60,"=========="
;... W !,"TOTAL",?60,$J(ABSPICNT,10)
;.. E W !,ABSPINS," (`",ABSPIIEN,")",?60,$J(ABSPICNT,10)
;.. I $$EOPQ^ABSPOSU8(3,,"D HEADING^"_$T(+0)) S ABSPINS="ZZZZZ"
;D ENDRPT^ABSPOSU5()
;W @IOF
;Q
;HEADING ;
;W @IOF
;N RPTDATE S RPTDATE=$$NOWEXT^ABSPOSU1
;W "Count of POS Claims not Passed to 3PB by Insurer (",$T(+0),")",?60,RPTDATE
;W !!,"Insurer",?60,"Count"
;W !,DASHES
;Q
ABSPOSMI ; IHS/SD/RLT - POS Claims not Passed to 3PB ; [ 09/18/07 02:00 PM ]
+1 ;;1.0;PHARMACY POINT OF SALE;**22,28**;SEP 18, 2007;Build 38
+2 ;----------------------------------------------------------
+3 ;IHS/OIT/SCR - 09/24/08 patch 28 - commented out to remove HOLD functionality introduced
+4 ; by patch 22
+5 ;----------------------------------------------------------
+6 QUIT
+7 ;----------------------------------------------------------
+8 ;
+9 ;EN ;EP
+10 ;
+11 ;K ^TMP("ABSPOSMI",$J)
+12 ;W @IOF
+13 ;W "Count of POS Claims not Passed to 3PB by Insurer",!
+14 ;W !
+15 ;N POP D ^%ZIS Q:$G(POP)
+16 ;D GETDATA
+17 ;U IO
+18 ;D DISDATA
+19 ;D ^%ZISC
+20 ;K ^TMP("ABSPOSMI",$J)
+21 ;Q
+22 ;
+23 ;GETDATA ;
+24 ;N ABSPLOG,ABSPTYPE,ABSPIIEN,ABSPINS
+25 ;S ABSPLOG=0
+26 ;F S ABSPLOG=$O(^ABSPHOLD(ABSPLOG)) Q:'+ABSPLOG D
+27 ;. S ABSPTYPE=$P($G(^ABSPHOLD(ABSPLOG,0)),U,2)
+28 ;. S ABSPIIEN=""
+29 ;. I ABSPTYPE="P" S ABSPIIEN=$P($G(^ABSPHOLD(ABSPLOG,"P")),U,8)
+30 ;. I ABSPTYPE="R" S ABSPIIEN=$P($G(^ABSPHOLD(ABSPLOG,"R")),U,3)
+31 ;. Q:ABSPIIEN=""
+32 ;. S ABSPINS=$$GET1^DIQ(9999999.18,ABSPIIEN_",",.01) ;name
+33 ;. S $P(^TMP("ABSPOSMI",$J,ABSPINS,ABSPIIEN),U)=+$P($G(^TMP("ABSPOSMI",$J,ABSPINS,ABSPIIEN)),U)+1
+34 ;. S $P(^TMP("ABSPOSMI",$J,"ZZZTOTAL",1),U)=+$P($G(^TMP("ABSPOSMI",$J,"ZZZTOTAL",1)),U)+1
+35 ;Q
+36 ;DISDATA ;
+37 ;N DASHES
+38 ;S $P(DASHES,"-",81)=""
+39 ;N ABSPINS,ABSPIIEN,ABSPICNT
+40 ;D HEADING
+41 ;I '$D(^TMP("ABSPOSMI",$J)) D Q
+42 ;. W !,"No held 3PB claims found!"
+43 ;. D ENDRPT^ABSPOSU5()
+44 ;S ABSPINS=""
+45 ;F S ABSPINS=$O(^TMP("ABSPOSMI",$J,ABSPINS)) Q:ABSPINS="" D
+46 ;. S ABSPIIEN=0
+47 ;. F S ABSPIIEN=$O(^TMP("ABSPOSMI",$J,ABSPINS,ABSPIIEN)) Q:'+ABSPIIEN D
+48 ;.. S ABSPICNT=$G(^TMP("ABSPOSMI",$J,ABSPINS,ABSPIIEN))
+49 ;.. I ABSPINS="ZZZTOTAL" D
+50 ;... W !,?60,"=========="
+51 ;... W !,"TOTAL",?60,$J(ABSPICNT,10)
+52 ;.. E W !,ABSPINS," (`",ABSPIIEN,")",?60,$J(ABSPICNT,10)
+53 ;.. I $$EOPQ^ABSPOSU8(3,,"D HEADING^"_$T(+0)) S ABSPINS="ZZZZZ"
+54 ;D ENDRPT^ABSPOSU5()
+55 ;W @IOF
+56 ;Q
+57 ;HEADING ;
+58 ;W @IOF
+59 ;N RPTDATE S RPTDATE=$$NOWEXT^ABSPOSU1
+60 ;W "Count of POS Claims not Passed to 3PB by Insurer (",$T(+0),")",?60,RPTDATE
+61 ;W !!,"Insurer",?60,"Count"
+62 ;W !,DASHES
+63 ;Q