Changeset 573 for ccr


Ignore:
Timestamp:
Oct 13, 2009, 7:58:45 PM (15 years ago)
Author:
George Lilly
Message:

some fixes to the MXML wrapper

File:
1 edited

Legend:

Unmodified
Added
Removed
  • ccr/trunk/p/C0CMXML.m

    r572 r573  
    2121 ;
    2222TEST ;
    23  S DOCID=$$PARSE("^GPL")
     23 S C0CXMLIN=$NA(^TMP("C0CMXML",$J))
     24 W $$FTG^%ZISH("/home/vademo2/EHR/p/","mxml-test.xml",$NA(@C0CXMLIN@(1)),3)
     25 S C0CDOCID=$$PARSE(C0CXMLIN)
    2426 S REDUX="//ContinuityOfCareRecord/Body"
    2527 D XPATH(1,"/","GIDX","GARY",,REDUX)
     
    4850 S @ZXIDX@(NEWPATH)=ZOID ; ADD THE XPATH FOR THIS NODE TO THE XPATH INDEX
    4951 N GD S GD=$$DATA(ZOID) ; SEE IF THERE IS DATA FOR THIS NODE
    50  I GD'=0 S @ZXPARY@(NEWPATH)=GD ; IF YES, ADD IT TO THE XPATH ARRAY
     52 I GD'="" S @ZXPARY@(NEWPATH)=GD ; IF YES, ADD IT TO THE XPATH ARRAY
    5153 N ZFRST S ZFRST=$$FIRST(ZOID) ; SET FIRST CHILD
    5254 I ZFRST'=0 D  ; THERE IS A CHILD
     
    7173 ;
    7274FIRST(ZOID) ;RETURNS THE OID OF THE FIRST CHILD OF ZOID
    73  Q $$CHILD^MXMLDOM(DOCID,ZOID)
     75 Q $$CHILD^MXMLDOM(C0CDOCID,ZOID)
    7476 ;
    7577TAG(ZOID) ; RETURNS THE XML TAG FOR THE NODE
    76  Q $$NAME^MXMLDOM(DOCID,ZOID)
     78 Q $$NAME^MXMLDOM(C0CDOCID,ZOID)
    7779 ;
    7880NXTSIB(ZOID) ; RETURNS THE NEXT SIBLING
    79  Q $$SIBLING^MXMLDOM(DOCID,ZOID)
     81 Q $$SIBLING^MXMLDOM(C0CDOCID,ZOID)
    8082 ;
    8183DATA(ZOID) ; RETURNS DATA FOR THE NODE
    8284 N ZT,ZN S ZT=""
    83  S ZN=$$TEXT^MXMLDOM(DOCID,ZOID,"ZT")
     85 S C0CDOM=$NA(^TMP("MXMLDOM",$J,C0CDOCID))
     86 Q $G(@C0CDOM@(ZOID,"T",1))
     87 S ZN=$$TEXT^MXMLDOM(C0CDOCID,ZOID,"ZT")
    8488 I $G(ZT) ZWR ZT
    8589 Q $G(ZT)
Note: See TracChangeset for help on using the changeset viewer.