Changeset 1586 for ccr/trunk/p/C0CCPT.m
- Timestamp:
- Oct 30, 2012, 1:11:02 PM (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
ccr/trunk/p/C0CCPT.m
r1544 r1586 1 1 C0CCPT ;;BSL;RETURN CPT DATA; 2 ;;1.2;C0C;;May 11, 2012;Build 47 3 ;Sequence Managers Software GPL;;;;;Build 2 4 ;Copied into C0C namespace from SQMCPT with permission from 5 ;Brian Lord - and with our thanks. gpl 01/20/2010 2 ;;1.2;CCD/CCR GENERATION UTILITIES;;Oct 30, 2012;Build 50 3 ; (C) George Lilly 2010 4 ; 5 ; This program is free software: you can redistribute it and/or modify 6 ; it under the terms of the GNU Affero General Public License as 7 ; published by the Free Software Foundation, either version 3 of the 8 ; License, or (at your option) any later version. 9 ; 10 ; This program is distributed in the hope that it will be useful, 11 ; but WITHOUT ANY WARRANTY; without even the implied warranty of 12 ; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 ; GNU Affero General Public License for more details. 14 ; 15 ; You should have received a copy of the GNU Affero General Public License 16 ; along with this program. If not, see <http://www.gnu.org/licenses/>. 17 ; 6 18 ENTRY(DFN,STDT,ENDDT,TXT) ;BUILD TOTAL ARRAY OF ALL IEN'S FOR TIU NOTES 7 19 ;DFN=PATIENT IEN … … 10 22 ;TXT=INCLUDE TEXT FROM ENCOUNTER NOTE 11 23 ;THAT FALL INSIDE DATA RANGE. IF NO STDT OR ENDDT ASSUME 12 13 14 15 16 17 18 19 20 21 24 ;ALL INCLUSIVE IN THAT DIRECTION 25 ;LIST OF TIU DOCS IN ^TIU(8925,"ACLPT",3,DFN) 26 ;BUILD INTO NOTE(Y)="" 27 S U="^",X="" 28 F S X=$O(^TIU(8925,"ACLPT",3,DFN,X)) Q:X="" D 29 . S Y="" 30 . F S Y=$O(^TIU(8925,"ACLPT",3,DFN,X,Y)) Q:Y="" D 31 .. S NOTE(Y)="" 32 ;NOW DELETE ANY NOTES THAT DON'T FALL INTO DATE RANGE 33 ;GET DATE OF NOTE 22 34 ;RUT 3120109 Changing DATE in FILMAN's FORMAT 23 ; ;OHUM/RUT 3111228 Date Range for Notes24 35 ;OHUM/RUT 3111228 Date Range for Notes 36 ;S STDT=^TMP("C0CCCR","TIULIMIT") D NOW^%DTC S ENDDT=X 25 37 N FLAGS1,FLAGS2 26 38 S FLAGS1=$P(^C0CPARM(1,2),"^",1) S STDT=$$HTOF^C0CVALID(FLAGS1) 27 39 S FLAGS2=$P(^C0CPARM(1,2),"^",2) S ENDDT=$$HTOF^C0CVALID(FLAGS2) 28 40 ;S STDT=^TMP("C0CCCR","TIULIMIT"),ENDDT=^TMP("C0CCCR","TIUSTART") 29 ;;OHUM/RUT41 ;OHUM/RUT 30 42 ;RUT 31 32 33 34 35 36 37 38 43 S Z="" 44 F S Z=$O(NOTE(Z)) Q:Z="" D 45 . S DT=$P(^TIU(8925,Z,0),U,7) 46 . I $G(STDT)]"" D 47 .. I STDT>DT S NOTE(Z)="D" ;SET NOTE TO BE DELETED 48 . I $G(ENDDT)]"" D 49 .. I ENDDT<DT S NOTE(Z)="D" 50 . I NOTE(Z)="D" K NOTE(Z) 39 51 D VISIT 40 52 Q 41 53 VISIT ;GET VISIT INFO FOR A GIVEN NOTE. BUILD INTO RETURN ARRAY .VISIT 42 54 S ILST=1,X0="",X12="",VISIT="",LST="",X811=""
Note:
See TracChangeset
for help on using the changeset viewer.