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

ABPAEEC1.m

Go to the documentation of this file.
ABPAEEC1 ;ENTER/EDT/PVT INS CLAIMS - PART 2; [ 07/09/91  11:21 AM ]
 ;;1.4;AO PVT-INS TRACKING;*0*;IHS-OKC/KJR;JULY 25, 1991
 Q  ;;NOT AN ENTRY POINT
WRITE F ABPAJ=3:1 Q:$P(ABPATEXT,";",ABPAJ)=""  D
 .S @("P"_ABPAJ)=$P(ABPATEXT,";",ABPAJ)
 W ! S DX=P5,DY=P6 S:IOST["QUME" DY=DY+1 X XY
 W P3,$J(P4,22) W:$D(ABPAEOL)=1 @(ABPAEOL)
 I $D(P7)=1 W " " W:$D(@P7)=1 @P7
 Q
 ;
REVON S DX=0,DY=19 W ! X XY D EOP^ABPAMAIN W:IOST["QUME" !
 W:$D(ABPARON) @(ABPARON)
 Q
 ;
SCREEN S ABPAHD1="ENTER/EDIT CLAIM DATA" D HEADER^ABPAMAIN
 F ABPAI=1:1 S ABPATEXT=$T(PROMPT+ABPAI) Q:ABPATEXT=""  D WRITE
 W !,ABPALL
 Q
 ;
EDIT D REVON W "Select FIELD NUMBER to edit (4 - 8)"
 W:$D(ABPARON)=1 @(ABPAROFF)
 R !,"FIELD NUMBER: ",ABPAI:DTIME I $T=0!(ABPAI["^")!(ABPAI="") G XIT
 I ABPAI["?" D  G EDIT
 .W "  -- ENTER A NUMBER BETWEEN 4 AND 8" H 3
 I +ABPAI>0&(+ABPAI<4) D  G EDIT
 .W *7,"  --  SORRY, YOU ARE NOT ALLOWED TO CHANGE THIS FIELD" H 3
 I +ABPAI=0!(+ABPAI>8) D  G EDIT
 .W *7,"  -- INVAILID SELECTION" H 3
 S LBL="FLD"_+ABPAI K DIC,DIE,DA,DR,X,Y D @LBL
 G EDIT
 ;
FLD4 S DA(1)=+ABPATDFN,DA=+ABPACDFN,DIE="^ABPVAO("_DA(1)_",1,",DR=.01
 S DIE("NO^")="" D REVON W "Enter the DATE OF SERVICE being billed"
 W:$D(ABPARON)=1 @(ABPAROFF)
 D ^DIE K DIC S DIC="^ABPVAO("_DA(1)_",1,",DIC(0)="Z"
 W:$D(ABPARON)=1 @(ABPAROFF)
 D ^DIC S ABPADOS=Y(0,0)
 D:$Y>3 SCREEN S ABPATEXT=$T(PROMPT+4) D WRITE
 Q
 ;
FLD5 S DA(1)=+ABPATDFN,DA=+ABPACDFN,DIE="^ABPVAO("_DA(1)_",1,",DR=.04
 S DIE("NO^")="" D REVON
 S ABPAMESS="VISIT TYPE - ""O"", ""I"", ""P"", or ""D""" W ABPAMESS
 W:$D(ABPARON)=1 @(ABPAROFF)
 D ^DIE S ABPATYPE=X
 I ABPATYPE="O" D
 .S ABPATYPE="OUTPATIENT",DR=".05////1" D ^DIE S ABPADV=1
 S:ABPATYPE="I" ABPATYPE="INPATIENT (HOSPITAL ONLY)"
 I ABPATYPE="P" D
 .S ABPATYPE="INPATIENT (PHYSICIAN ONLY)",DR=".05////0" D ^DIE
 .S ABPADV=0
 I ABPATYPE="D" D
 .S ABPATYPE="DENTAL",DR=".05////1" D ^DIE S ABPADV=1
 D:$Y>21 SCREEN S ABPATEXT=$T(PROMPT+5) D WRITE
 I ABPATYPE["HOSPITAL" G FLD6
 S ABPATEXT=$T(PROMPT+6) D WRITE
 Q
 ;
FLD6 I ABPATYPE["PHYSICIAN" D  Q
 .W *7," - Cannot edit in-patient physician workload  " H 3
 I ABPATYPE["OUTPATIENT" D  Q
 .W *7," - Cannot edit out-patient workload  " H 3
 I ABPATYPE["DENTAL" D  Q
 .W *7," - Cannot edit dental workload  " H 3
 S DA(1)=+ABPATDFN,DA=+ABPACDFN,DIE="^ABPVAO("_DA(1)_",1,",DR=.05
 S DIE("NO^")="" D REVON
 W "Number of outpatient VISITS or inpatient DAYS (0 - 50)"
 W:$D(ABPARON) @(ABPAROFF)
 D ^DIE S ABPADV=X
 I ((ABPATYPE["INPATIENT")!(ABPATYPE["DENTAL"))&(+ABPADV'>0) D  G FLD6
 .W *7," - Workload must be greater than zero  " H 3
 D:$Y>21 SCREEN S ABPATEXT=$T(PROMPT+6) D WRITE
 Q
 ;
FLD7 S DA(1)=+ABPATDFN,DA=+ABPACDFN,DIE="^ABPVAO("_DA(1)_",1,",DR=.06
 S DIE("NO^")="" D REVON
 W "Name of the INSURANCE COMPANY being billed"
 W:$D(ABPARON)=1 @(ABPAROFF)
 D ^DIE S ABPAINS=X,ABPAINS=$P(^AUTNINS(+ABPAINS,0),"^")
 S DR=.062 D ^DIE S ABPAPHNM=X
 S DR=.064 D ^DIE S ABPAPNUM=X
 D:$Y>3 SCREEN S ABPATEXT=$T(PROMPT+7) D WRITE
 Q
 ;
FLD8 S DA(1)=+ABPATDFN,DA=+ABPACDFN,DIE="^ABPVAO("_DA(1)_",1,",DR=.07
 S DIE("NO^")="" D REVON
 W "Enter the dollar AMOUNT being claimed (0 - 99999)"
 W:$D(ABPARON)=1 @(ABPAROFF) D ^DIE
 S ABPAAMT="$"_$J(X,8,2) D:$Y>3 SCREEN S ABPATEXT=$T(PROMPT+8) D WRITE
 Q
 ;
FLD9 S DA(1)=+ABPATDFN,DA=+ABPACDFN,DIE="^ABPVAO("_DA(1)_",1,",DR=".11R~T"
 S DIE("NO^")="" D REVON
 W "Enter the date of the BILL LOG where this bill can be found"
 W:$D(ABPARON)=1 @(ABPAROFF) D ^DIE S DR=".115///"_X D ^DIE
 Q
 ;
XIT G START^ABPAEEC0
 ;
PROMPT ;;FLD #;TITLE;X-POSITION;Y-POSITION;VARIABLE NAME
 ;;(1)   ;Patient Name:;7;8;ABPAPNAM
 ;;(2)   ;Facility:;7;9;ABPAFAC
 ;;(3)   ;Health Record Number:;7;10;ABPAHRN
 ;;(4)   ;Date of Service:;7;11;ABPADOS
 ;;(5)   ;Visit Type:;7;12;ABPATYPE
 ;;(6)   ;Days or Visits:;7;13;ABPADV
 ;;(7)   ;Insurance Company:;7;14;ABPAINS
 ;;   (a);Policy Holder Name:;7;15;ABPAPHNM
 ;;   (b);Policy Number:;7;16;ABPAPNUM
 ;;(8)   ;Claim Amount:;7;17;ABPAAMT