Changeset 174
- Timestamp:
- Sep 28, 2008, 11:56:23 AM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
ccr/trunk/p/CCRMEDS.m
r173 r174 112 112 . ; ==>[7P:51.2] ^ (#7) SCHEDULE [8F] ^ (#8) VERB [9F] ^ 113 113 . ; 114 115 116 . . S @MAP@("M EDDIRECTIONDESCRIPTIONTEXT",DIRNUM)="" ; This is reserved for systems not able to generate the sig in components.117 . . S @MAP@("M EDDOSEINDICATOR",DIRNUM)="1" ; means that we are specifying it. See E2369-05.114 . N DIRNUM S DIRNUM=0 ; Sigline number 115 . F S DIRNUM=$O(^PSRX(RXIEN,6,DIRNUM)) Q:DIRNUM="" D 116 . . S @MAP@("M",DIRNUM,"MEDDIRECTIONDESCRIPTIONTEXT")="" ; This is reserved for systems not able to generate the sig in components. 117 . . S @MAP@("M",DIRNUM,"MEDDOSEINDICATOR")="1" ; means that we are specifying it. See E2369-05. 118 118 . . N SIGDATA S SIGDATA=^PSRX(RXIEN,6,DIRNUM,0) 119 . . S @MAP@("M EDDELIVERYMETHOD",DIRNUM)=$P(SIGDATA,U,9)120 . . S @MAP@("M EDDOSEVALUE",DIRNUM)=$P(SIGDATA,U,1)121 . . S @MAP@("M EDDOSEUNIT",DIRNUM)=@MAP@("MEDCONCUNIT")122 . . S @MAP@("M EDRATEVALUE",DIRNUM)="" ; For inpatient123 . . S @MAP@("M EDRATEUNIT",DIRNUM)="" ; For inpatient124 . . S @MAP@("M EDVEHICLETEXT",DIRNUM)="" ; For inpatient125 . . S @MAP@("M EDDIRECTIONROUTETEXT",DIRNUM)=$$GET1^DIQ(51.2,$P(SIGDATA,U,7),.01)126 . . S @MAP@("M EDFREQUENCYVALUE",DIRNUM)=$P(SIGDATA,U,8)119 . . S @MAP@("M",DIRNUM,"MEDDELIVERYMETHOD")=$P(SIGDATA,U,9) 120 . . S @MAP@("M",DIRNUM,"MEDDOSEVALUE")=$P(SIGDATA,U,1) 121 . . S @MAP@("M",DIRNUM,"MEDDOSEUNIT")=@MAP@("MEDCONCUNIT") 122 . . S @MAP@("M",DIRNUM,"MEDRATEVALUE")="" ; For inpatient 123 . . S @MAP@("M",DIRNUM,"MEDRATEUNIT")="" ; For inpatient 124 . . S @MAP@("M",DIRNUM,"MEDVEHICLETEXT")="" ; For inpatient 125 . . S @MAP@("M",DIRNUM,"MEDDIRECTIONROUTETEXT")=$$GET1^DIQ(51.2,$P(SIGDATA,U,7),.01) 126 . . S @MAP@("M",DIRNUM,"MEDFREQUENCYVALUE")=$P(SIGDATA,U,8) 127 127 . . ; Invervals... again another call. 128 128 . . ; In the wisdom of the original programmers, the schedule is a free text field … … 141 141 . . . N SUB S SUB=$O(SCHEDATA(0)) 142 142 . . . S INTERVAL=SCHEDATA(SUB,2) 143 . . S @MAP@("M EDINTERVALVALUE",DIRNUM)=INTERVAL144 . . S @MAP@("M EDINTERVALUNIT",DIRNUM)="Minute"145 . . S @MAP@("M EDDURATIONVALUE",DIRNUM)=$P(SIGDATA,U,5)146 . . S @MAP@("M EDDURATIONUNIT",DIRNUM)=""147 . . S @MAP@("M EDPRNFLAG",DIRNUM)=$P(SIGDATA,U,8)["PRN"148 . . S @MAP@("M EDPROBLEMOBJECTID",DIRNUM)=""149 . . S @MAP@("M EDPROBLEMTYPETXT",DIRNUM)=""150 . . S @MAP@("M EDPROBLEMDESCRIPTION",DIRNUM)=""151 . . S @MAP@("M EDPROBLEMCODEVALUE",DIRNUM)=""152 . . S @MAP@("M EDPROBLEMCODINGSYSTEM",DIRNUM)=""153 . . S @MAP@("M EDPROBLEMCODINGVERSION",DIRNUM)=""154 . . S @MAP@("M EDPROBLEMSOURCEACTORID",DIRNUM)=""155 . . S @MAP@("M EDSTOPINDICATOR",DIRNUM)=""156 . . S @MAP@("M EDDIRSEQ",DIRNUM)=DIRNUM157 158 . . S @MAP@("M EDMULDIRMOD",DIRNUM)=$S(DIRMOD="T":"THEN",DIRMOD="A":"AND",DIRMOD="X":"EXCEPT",1:"")143 . . S @MAP@("M",DIRNUM,"MEDINTERVALVALUE")=INTERVAL 144 . . S @MAP@("M",DIRNUM,"MEDINTERVALUNIT")="Minute" 145 . . S @MAP@("M",DIRNUM,"MEDDURATIONVALUE")=$P(SIGDATA,U,5) 146 . . S @MAP@("M",DIRNUM,"MEDDURATIONUNIT")="" 147 . . S @MAP@("M",DIRNUM,"MEDPRNFLAG")=$P(SIGDATA,U,8)["PRN" 148 . . S @MAP@("M",DIRNUM,"MEDPROBLEMOBJECTID")="" 149 . . S @MAP@("M",DIRNUM,"MEDPROBLEMTYPETXT")="" 150 . . S @MAP@("M",DIRNUM,"MEDPROBLEMDESCRIPTION")="" 151 . . S @MAP@("M",DIRNUM,"MEDPROBLEMCODEVALUE")="" 152 . . S @MAP@("M",DIRNUM,"MEDPROBLEMCODINGSYSTEM")="" 153 . . S @MAP@("M",DIRNUM,"MEDPROBLEMCODINGVERSION")="" 154 . . S @MAP@("M",DIRNUM,"MEDPROBLEMSOURCEACTORID")="" 155 . . S @MAP@("M",DIRNUM,"MEDSTOPINDICATOR")="" 156 . . S @MAP@("M",DIRNUM,"MEDDIRSEQ")=DIRNUM 157 . . N DIRMOD S DIRMOD=$P(SIGDATA,U,6) 158 . . S @MAP@("M",DIRNUM,"MEDMULDIRMOD")=$S(DIRMOD="T":"THEN",DIRMOD="A":"AND",DIRMOD="X":"EXCEPT",1:"") 159 159 . ; 160 160 . ; --- END OF DIRECTIONS --- … … 167 167 . N RESULT S RESULT=$NA(^TMP("GPLCCR",$J,"MAPPED")) 168 168 . K @RESULT 169 169 . D MAP^GPLXPATH(MINXML,MAP,RESULT) 170 170 . ; D PARY^GPLXPATH(RESULT) 171 171 . D:MEDCOUNT=1 CP^GPLXPATH(RESULT,OUTXML) ; First one is a copy
Note:
See TracChangeset
for help on using the changeset viewer.