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

EC2P137B.m

Go to the documentation of this file.
EC2P137B ;ALB/DE - EC National Procedure Update ; 4/8/17 11:00am
 ;;2.0;EVENT CAPTURE;**137**;8 May 96;Build 5
 ;
 ;this routine is used as a post-init in a KIDS build
 ;to modify the EC National Procedure file (#725)
 ;
 Q
 ;
ADDPROC ;* add national procedures
 ;
 ;  ECXX is in format:
 ;   NAME^NATIONAL NUMBER^CPT CODE^FIRST NATIONAL NUMBER SEQUENCE
 ;   LAST NATIONAL NUMBER SEQUENCE
 ;
 N ECX,ECXX,ECDINUM,ECNAME,ECCODE,ECCPT,ECCOUNT,X,Y,DIC,DIE,DA,DR,DLAYGO,DINUM
 N ECADD,ECBEG,ECEND,ECCODX,ECNAMX,ECSEQ,ECLIEN,ECSTR,ECCPTN
 D MES^XPDUTL(" ")
 D BMES^XPDUTL("Adding new procedures to EC NATIONAL PROCEDURE File (#725)...")
 D MES^XPDUTL(" ")
 S ECDINUM=$O(^EC(725,9999),-1),ECCOUNT=$P(^EC(725,0),U,4)
 F ECX=1:1 S ECXX=$P($T(NEW+ECX),";;",2) Q:ECXX="QUIT"  D
 .S ECNAME=$P(ECXX,U,1),ECCODE=$P(ECXX,U,2),ECCPTN=$P(ECXX,U,3),ECCODX=ECCODE
 .S ECCPT=""
 .I ECCPTN'="" S ECCPT=$$FIND1^DIC(81,"","X",ECCPTN) I +ECCPT<1 D  Q
 ..S ECSTR="   CPT code "_ECCPTN_" not a valid code in CPT File."
 ..D MES^XPDUTL(" ")
 ..D BMES^XPDUTL("   ["_ECCODE_"] "_ECSTR)
 .S ECBEG=$P(ECXX,U,4),ECEND=$P(ECXX,U,5),ECNAMX=ECNAME
 .I ECBEG="" S X=ECNAME D FILPROC Q
 .F ECSEQ=ECBEG:1:ECEND D
 ..S ECADD="000"_ECSEQ,ECADD=$E(ECADD,$L(ECADD)-2,$L(ECADD))
 ..;S ECNAME=ECNAMX_ECADD,X=ECNAME,ECCODE=ECCODX_ECADD
 ..I $E(ECCODX,1,3)'="RCM" S ECNAME=ECNAMX_ECSEQ,X=ECNAME,ECCODE=ECCODX_ECADD
 ..E  S ECNAME=ECNAMX_$E(ECADD,2,99),X=ECNAME,ECCODE=ECCODX_$E(ECADD,2,99)
 ..D FILPROC
 S $P(^EC(725,0),U,4)=ECCOUNT,X=$O(^EC(725,999999),-1),$P(^EC(725,0),U,3)=X
 Q
 ;
FILPROC ;File national procedures
 I '$D(^EC(725,"D",ECCODE)) D
 .S ECDINUM=ECDINUM+1,DINUM=ECDINUM,DIC(0)="L",DLAYGO=725,DIC="^EC(725,"
 .S DIC("DR")="1////^S X=ECCODE;4///^S X=ECCPT"
 .D FILE^DICN
 .I +Y>0 D
 ..S ECCOUNT=ECCOUNT+1
 ..D MES^XPDUTL(" ")
 ..S ECSTR="   Entry #"_+Y_" for "_$P(Y,U,2)
 ..S ECSTR=ECSTR_$S(ECCPT'="":" [CPT: "_ECCPT_"]",1:"")_" ("_ECCODE_")"
 ..D BMES^XPDUTL(ECSTR)
 ..D BMES^XPDUTL("      ...successfully added.")
 .I Y=-1 D
 ..D MES^XPDUTL(" ")
 ..D BMES^XPDUTL("ERROR when attempting to add "_ECNAME_" ("_ECCODE_")")
 I $D(^EC(725,"DL",ECCODE)) D
 .S ECLIEN=$O(^EC(725,"DL",ECCODE,""))
 .D MES^XPDUTL(" ")
 .D BMES^XPDUTL("   Your site has a local procedure (entry #"_ECLIEN_") in File #725")
 .D BMES^XPDUTL("   which uses "_ECCODE_" as its National Number.")
 .D BMES^XPDUTL("   Please inactivate this local procedure.")
 .K Y
 Q
NEW ;national procedures to add;;descript^nation #^CPT code^beg seq^end seq
 ;;NON-OR REC TIME CATH LAB^NO001^
 ;;NON-OR REC TIME ENDOSCOPY^NO002^
 ;;NON-OR REC TIME RADIOLOGY^NO003^
 ;;NON-OR REC TIME CARDIOLOGY^NO004^
 ;;NON-OR REC TIME OTHER^NO005^
 ;;PHONE CALL W/PT EA AD'L 5M^NU216^
 ;;OT EVAL- LOW COMPLEX^OT001^97165
 ;;OT EVAL - MOD COMPLEX^OT002^97166
 ;;OT EVAL - HIGH COMPLEX^OT003^97167
 ;;OT REEVAL EST PLAN OF CARE^OT004^97168
 ;;PT EVAL- LOW COMPLEX^PT001^97161
 ;;PT EVAL - MOD COMPLEX^PT002^97162
 ;;PT EVAL - HIGH COMPLEX^PT003^97163
 ;;PT REEVAL EST PLAN OF CARE^PT004^97164
 ;;HEALTH BEH INTERVENT 15M^RC103^96152
 ;;COGNITIVE SKILLS DVMT 15M^RC104^97532
 ;;EXERCISE GRP^RC105^S9451
 ;;VESTIBULAR REHAB TRMT^RC106^97112
 ;;HEALTH & BEH INTER, GRP^RC107^96153
 ;;HEALTH & BEH INTER, FAM W/PT^RC108^96154
 ;;HEALTH & BEH INTER, FAM NO PT^RC109^96155
 ;;THER PROC, GAIT TRNG, IND^RC110^97116
 ;;UNLISTED THER PROCEDURE^RC111^97139
 ;;WHCHAIR MGMT/PROP TRNG IND^RC112^97542
 ;;PHYSICAL PERF TEST/MEASURE IND^RC113^97750
 ;;DEVICE FILL ORTH/PROS USE^RC114^97762
 ;;TELEPHONE SERVICE 11-20M^RC115^98967
 ;;TELEPHONE SERVICE 21-30M^RC116^98968
 ;;MED TESTIMONY/DEPOSITIONS^RC117^99075
 ;;SPECIAL RPT/FORM NON-STD^RC118^99080
 ;;NON-MD TEAM CONF W/PT^RC119^99366
 ;;DRIVE TIME, 15M^RC120^
 ;;HOME VISIT BY NON-MD NOS^RC121^99600
 ;;SCHD INTERDISCP TEAM CONF W/PT^RC122^G0175
 ;;TELEHEALTH^RC123^Q3014
 ;;WT MGMT NON-MD EA SESSION^RC124^S9449
 ;;CASE MGMT IND^RC125^T1016
 ;;THERAPEUTIC ACTIVITY IND^RC126^97530
 ;;THERAPEUTIC PROC GRP^RC127^97150
 ;;THERAPEUTIC PROC IND 15M^RC128^97110
 ;;EDUC AND TRNG, IND 30M^RC129^98960
 ;;EDUC AND TRNG, 2-4 PT 30M^RC130^98961
 ;;EDUC AND TRNG, 5-8 PT 30M^RC131^98962
 ;;ED/TRNG  F2F 2-4 PTS 30M^SL011^98961
 ;;NC-ED/TRNG  F2F 2-4 PTS 30M^SL012^
 ;;ED/TRNG  F2F 5-8 PTS 30M^SL013^98962
 ;;NC-ED/TRNG  F2F 5-8 PTS 30M^SL014^
 ;;ED/TRNG  F2F IND 30M^SL015^98960
 ;;NC-ED/TRNG  F2F IND 30M^SL016^
 ;;PT ED GRP EA SESSION^SL017^S9446
 ;;NC-PT ED GRP EA SESSION^SL018^
 ;;PT ED IND EA SESSION^SL019^S9445
 ;;NC-PT ED IND EA SESSION^SL020^
 ;;TELEMONITORING^SL021^S9110
 ;;NC-TELEMONITORING^SL022^
 ;;TELEPHONE CLINIC 5-10M^SL023^98966
 ;;NC-TELEPHONE CLINIC 5-10M^SL024^
 ;;TELEPHONE CLINIC 11-20M^SL025^98967
 ;;NC-TELEPHONE CLINIC 11-20M^SL026^
 ;;TELEPHONE CLINIC 21-30M^SL027^98968
 ;;NC-TELEPHONE CLINIC 21-30M^SL028^
 ;;CPAP CLINIC^SL029^99201
 ;;NC-CPAP CLINIC^SL030^
 ;;DME SUPPLY PROVISION^SL031^98961
 ;;NC-DME SUPPLY PROVISION^SL032^
 ;;DOCUMENT DME ORDER^SL036^
 ;;DATA DOWNLOAD^SL039^99091
 ;;NC-DATA DOWNLOAD^SL040^
 ;;MASK REFITTING^SL041^K0739
 ;;NC-MASK REFITTING^SL042^
 ;;EQUIPMENT REPAIR^SL043^K0739
 ;;NC-EQUIPMENT REPAIR^SL044^
 ;;CHART REVIEW^SL052^
 ;;DME SUPPLY COLLECTION^SL054^
 ;;SUPPLY ORDER REFILL^SL056^
 ;;SCHEDULING^SL058^
 ;;DEFECTIVE EQUIP RETURN^SL060^
 ;;INTERACTIVE COMPLEXITY^SW140^90785
 ;;PROLONGED CARE F2F OPT 1ST HR^SW141^99354
 ;;PROLONGED CARE F2F OPT EA AD'L 30M^SW142^99355
 ;;PROLONGED CARE F2F IPT^SW143^99356
 ;;PROLONGED CARE F2F IPT EA AD'L 30M^SW144^99357
 ;;PSYCHOTHERAPY CRISIS 16-29M^SW145^90832
 ;;PSYCHOTHERAPY CRISIS 1ST HR^SW146^90839
 ;;PSYCHOTHERAPY CRISIS  EA AD'L 30M^SW147^90840
 ;;CONSULTATION WITH FAMILY^SW148^90887
 ;;IND PSYCHOPHYSIO THPY BIOFDBACK 30M^SW149^90875
 ;;IND PSYCHOPHYSIO THPY BIOFDBACK 45M^SW150^90876
 ;;TEAM CONFERENCE W/O PT W/ PRESCRIBER 30M^SW151^99367
 ;;PROGRAM INTAKE ASSESSMENT^SW153^T1023
 ;;HOME VISIT MARRIAGE COUNSEL^SW154^99510
 ;;PT EDUCATION, GRP^SW155^S9446
 ;;PT EDUCATION, IND^SW156^S9445
 ;;SMOKING CESSATION CLASS^SW157^S9453
 ;;STRESS MGMT CLASS^SW158^S9454
 ;;TRNG/EDUC R/T DISABLING MH PROBS^SW159^G0177
 ;;HEALTH & BEH ASSMT,EA 15M INITIAL^SW160^96150
 ;;HEALTH & BEH REASSMT 15M^SW161^96151
 ;;HEALTH & BEH INTERVENT 15M FAM W/ PT^SW162^96154
 ;;HEALTH & BEH INTERVENT 15M FAM W/O PT^SW163^96155
 ;;HOSPICE REFERRAL VISIT^SW164^S0255
 ;;ETOH &/OR DRUG ABUSE STRUCTURED ASSMT 15-30M^SW165^G0396
 ;;ETOH &/OR DRUG ABUSE STRUCTURED ASSMT >30M^SW166^G0397
 ;;PSYCH EVAL HOSP RECS MED DX^SW167^90885
 ;;RESULTS INTERP EXAMS TO OTHERS^SW168^90887
 ;;ENVIRON INTERVENT MED MGMT MH PT^SW169^90882
 ;;CASE MGMT ETOH/DRUG SERVICES^SW170^H0006
 ;;ETOH &/OR DRUG ASSMNT^SW171^H0001
 ;;BEH HEALTH IND/GRP COUNSEL TX 15M^SW172^H0004
 ;;GRP COUNSEL ETOH &/OR DRUG SERVICES^SW173^H0005
 ;;ETOH &/OR SA FAM/COUPLE COUNSEL^SW174^T1006
 ;;ETOH &/OR SA TX PLAN DVMT/MOD^SW175^T1007
 ;;BEH HEALTH COUNSEL THPY 15M^SW176^H0004
 ;;ETOH &/OR DRUG SERVICES GRP COUNSEL^SW177^H0005
 ;;ETOH &/OR DRUG SERVICES CRISIS OPT^SW178^H0007
 ;;PSYCHOEDUC SERVICE, 15M^SW179^H2027
 ;;ETOH &/OR DRUG SERVICES METHADONE^SW180^H0020
 ;;SECURE MESSAGES^SW181^98969
 ;;ADV DIRECTIVES EA AD'L30M^SW182^99498
 ;;QUIT
 ;
NAMECHG ;* change national procedure names
 ;
 ;  ECXX is in format:
 ;   NATIONAL NUMBER^NEW NAME
 ;
 N ECX,ECXX,ECDA,DA,DR,DIC,DIE,X,Y,ECSTR
 D MES^XPDUTL(" ")
 D BMES^XPDUTL("Changing names in EC NATIONAL PROCEDURE File (#725)...")
 D MES^XPDUTL(" ")
 F ECX=1:1 S ECXX=$P($T(CHNG+ECX),";;",2) Q:ECXX="QUIT"  D
 .I $D(^EC(725,"D",$P(ECXX,U,1))) D
 ..S ECDA=+$O(^EC(725,"D",$P(ECXX,U,1),0))
 ..I $D(^EC(725,ECDA,0)) D
 ...S DA=ECDA,DR=".01////^S X=$P(ECXX,U,2)",DIE="^EC(725," D ^DIE
 ...D MES^XPDUTL(" ")
 ...D MES^XPDUTL("   Entry #"_ECDA_" for "_$P(ECXX,U,1))
 ...D BMES^XPDUTL("      ... field (#.01) updated to  "_$P(ECXX,U,2)_".")
 .I '$D(^EC(725,"D",$P(ECXX,U,1))) D
 ..D MES^XPDUTL(" ")
 ..S ECSTR="Can't find entry for "_$P(ECXX,U,1)
 ..D BMES^XPDUTL(ECSTR_" ...field (#.01) not updated.")
 Q
 ;
CHNG ;name changes -national code #^new procedure name
 ;;NU007^NUTR PROB-NONE 10M
 ;;NU008^NUTR PROB-PREDICTED 10M
 ;;NU009^NUTR PROB-PRESENT 10M
 ;;NU019^PHONE 5-10M NO PT
 ;;NU020^PHONE 11-20M NO PT
 ;;NU021^PHONE 21-30M NO PT
 ;;NU022^PHONE 5-10M PROV
 ;;NU023^PHONE 11-20M PROV
 ;;NU024^PHONE 21-30M PROV
 ;;RC009^NON-MD TEAM CONF, NO PT
 ;;RC073^AQUATICTHER W/THER EX,IND
 ;;RC077^COMM REINT TRNG, IND 15M
 ;;RC081^PT ED NON-MD PROV IND SES
 ;;RC082^PT ED NON-MD PROV GRP SES
 ;;RC085^TELEPHONE SERVICE 5-10M
 ;;SD011^PREV RATE STATE DOM
 ;;SH011^PREV RATE STATE ADHC
 ;;SN011^PREV RATE STATE HOME
 ;;SW003^CASE MANAGEMENT
 ;;SW124^DISCH CONF PT, FAM OR S/O
 ;;SW076^HOME VISIT 15M
 ;;SW087^HOMEHEALTH F/U 15M
 ;;QUIT