1 | DG53729R ;ALB/JRC - Add NURSING HOME TREATING SPECIALTIES ; 2/21/07 12:31pm
|
---|
2 | ;;5.3;Registration;**729**;Aug 13, 1993;Build 59
|
---|
3 | ;Continuation of DG53729P
|
---|
4 | ;
|
---|
5 | EDIT ;Edit surgical specialties
|
---|
6 | N DS,DIE,DR,DGI,DGCD
|
---|
7 | S DIE="^DIC(45.3,"
|
---|
8 | S DIC(0)="X"
|
---|
9 | F DGI=1:1 S DGSPEC=$P($T(ESURGSP+DGI),";;",2) Q:DGSPEC="QUIT" D
|
---|
10 | .S DGERR=0
|
---|
11 | .S DGCD=$P(DGSPEC,U)
|
---|
12 | .S DGSPEC1=0 F DGII=0:0 S DGSPEC1=$O(^DIC(45.3,"B",DGCD,DGSPEC1)) Q:'DGSPEC1 D
|
---|
13 | ..S DA=DGSPEC1,DR="1///"_$P(DGSPEC,U,2)
|
---|
14 | ..D ^DIE
|
---|
15 | ..D BMES^XPDUTL(" ")
|
---|
16 | ..D BMES^XPDUTL(" ")
|
---|
17 | ..D BMES^XPDUTL(">>>"_$P(DGSPEC,U)_" code updated to "_$P(DGSPEC,U,2)_" in the Surgical Specialty file.>>>")
|
---|
18 | Q
|
---|
19 | ;
|
---|
20 | ESURGSP ;;Code^Specialty
|
---|
21 | ;;50^GENERAL SURGERY
|
---|
22 | ;;51^OB/GYN
|
---|
23 | ;;55^EAR, NOSE, THROAT (ENT)
|
---|
24 | ;;56^PLASTIC SURGERY
|
---|
25 | ;;58^THORACIC SURGERY
|
---|
26 | ;;60^ORAL SURGERY
|
---|
27 | ;;QUIT
|
---|
28 | Q
|
---|
29 | ;
|
---|
30 | PTFCAT ;Place inactive date in PTF EXPANDED CODE CATEGORY (#.03) field
|
---|
31 | ;Temporarily remove 'no editing' from Data Dictionary
|
---|
32 | N SAVXI,SAVXF,SAVXC,XI,XF,XC
|
---|
33 | S SAVXF=$P(^DD(45.88,.02,0),U,2) ;Flag field
|
---|
34 | S XF=$P(SAVXF,"I",1)_$P(SAVXF,"I",2,99) ;REMOVE THE 'I'
|
---|
35 | S SAVXI=$P(^DD(45.88,.03,0),U,2) ;Inactive Date field
|
---|
36 | S XI=$P(SAVXI,"I",1)_$P(SAVXI,"I",2,99) ;REMOVE THE 'I'
|
---|
37 | S SAVXC=$P(^DD(45.89,.01,0),U,2) ;Category field
|
---|
38 | S XC=$P(SAVXC,"I",1)_$P(SAVXC,"I",2,99) ;REMOVE THE 'I'
|
---|
39 | S $P(^DD(45.88,.02,0),U,2)=XF
|
---|
40 | S $P(^DD(45.88,.03,0),U,2)=XI
|
---|
41 | S $P(^DD(45.89,.01,0),U,2)=XC
|
---|
42 | N I,CAT,DIC,DIE,DR,X,Y,DGPCD
|
---|
43 | F I=1:1 S CAT=$P($T(PTFCAT1+I),";;",2) Q:CAT="QUIT" D
|
---|
44 | . S DIC="^DIC(45.88,",DIC(0)="X"
|
---|
45 | . S X=$P(CAT,"^")
|
---|
46 | . I $P(CAT,"^")="DIALYSIS TYPE" S DIC(0)="LM"
|
---|
47 | . D ^DIC
|
---|
48 | . I +Y>0 D
|
---|
49 | .. S DIE=DIC,DA=+Y
|
---|
50 | .. S DR=".03////"_$P(CAT,"^",2)
|
---|
51 | .. I $P(CAT,"^")="DIALYSIS TYPE" S DR=".02///8"
|
---|
52 | .. D ^DIE
|
---|
53 | ..I $P(CAT,"^")="DIALYSIS TYPE" D
|
---|
54 | ...D BMES^XPDUTL(">>>"_$P(CAT,"^")_" added to the PTF EXPANDED CODE CATEGORY File (#45.88).")
|
---|
55 | ..E D
|
---|
56 | ...D BMES^XPDUTL(">>>Inactive date added to category "_$P(CAT,"^")_" in the")
|
---|
57 | ...D MES^XPDUTL(" PTF EXPANDED CODE CATEGORY File (#45.88).<<<")
|
---|
58 | ;In file 45.89, add procedure codes to newly added DIALYSIS TYPE
|
---|
59 | F DGPCD=39.95,54.98,50.92 D
|
---|
60 | .S DIC="^ICD0(",DIC(0)="MX",X=DGPCD D ^DIC
|
---|
61 | .Q:+Y'>0
|
---|
62 | .I $D(^DIC(45.89,"ASPL",+Y_";ICD0(")) D Q
|
---|
63 | ..D MES^XPDUTL(">>>>Entry "_$P(Y,U,2)_" exists in PTF EXPANDED CODE File (#45.89).")
|
---|
64 | .S DIC="^DIC(45.89,",DIC(0)=""
|
---|
65 | .S DIC("DR")=".01///6"_";.02///"_DGPCD,X="DIALYSIS TYPE"
|
---|
66 | .K D0 D FILE^DICN
|
---|
67 | .I +Y<0 D Q
|
---|
68 | ..D MES^XPDUTL(">>>>Entry not added to PTF EXPANDED CODE File (#45.89). No further updating will occur.")
|
---|
69 | ..D MES^XPDUTL(" Please contact Customer Service for assistance.")
|
---|
70 | .D MES^XPDUTL(">>>>Entry "_$S($P(Y,U,3)=1:"added to",1:"exists in")_" PTF EXPANDED CODE File (#45.89).")
|
---|
71 | ;Place 'old' value back into Data Dictionary
|
---|
72 | S $P(^DD(45.88,.02,0),U,2)=SAVXF
|
---|
73 | S $P(^DD(45.88,.03,0),U,2)=SAVXI
|
---|
74 | S $P(^DD(45.89,.01,0),U,2)=SAVXC
|
---|
75 | K DIC,DIE,DA,DR,Y,X
|
---|
76 | ;
|
---|
77 | ;-Remove DIALYSIS TYPE trigger xref.
|
---|
78 | I $D(^DD(45.05,2,1,1)) D
|
---|
79 | .D BMES^XPDUTL(">>>Removing DIALYSIS TYPE trigger cross-reference.")
|
---|
80 | .D DELIX^DDMOD(45.05,2,1)
|
---|
81 | Q
|
---|
82 | PTFCAT1 ;- PTF EXPANDED CODE CATEGORY items to inactivate
|
---|
83 | ;;KIDNEY TRANSPLANT STATUS^3060701
|
---|
84 | ;;SUICIDE INDICATOR^3060701
|
---|
85 | ;;LEGIONNAIRE'S DISEASE^3060701
|
---|
86 | ;;SUBSTANCE ABUSE^3060701
|
---|
87 | ;;DIALYSIS TYPE^^8
|
---|
88 | ;;QUIT
|
---|