Mercurial > hg > ZopePubmanConnector
changeset 21:3562adeaba8b
only show non private links in getPublicationsFromContext
author | dwinter |
---|---|
date | Tue, 02 Jul 2013 14:47:49 +0200 |
parents | c91cfc8c3603 |
children | 2abc89d58140 |
files | zopePubmanConnector.py |
diffstat | 1 files changed, 14 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/zopePubmanConnector.py Tue Jul 02 13:04:39 2013 +0200 +++ b/zopePubmanConnector.py Tue Jul 02 14:47:49 2013 +0200 @@ -470,6 +470,7 @@ volumepath=".//{http://escidoc.mpg.de/metadataprofile/schema/0.1/types}volume" linkspath=""".//{http://www.escidoc.de/schemas/components/0.8}component/{http://www.escidoc.de/schemas/components/0.8}content[@storage="internal-managed"]""" + visibility=""".//{http://www.escidoc.de/schemas/components/0.8}component/{http://www.escidoc.de/schemas/components/0.8}properties/{http://escidoc.de/core/01/properties/}visibility""" #linkspath=""".//{http://www.escidoc.de/schemas/components/0.8}component/{http://www.escidoc.de/schemas/components/0.8}content[@storage="external-url"]""" #linkspath=".//{http://www.escidoc.de/schemas/components/0.8}component/{http://www.escidoc.de/schemas/components/0.8}content" citations=root.findall(objxpath) @@ -502,9 +503,20 @@ #</escidocComponents:properties> #<escidocComponents:content xlink:type="simple" xlink:title="P437.PDF" storage="internal-managed" # xlink:href="http://pubman.mpiwg-berlin.mpg.de/pubman/item/escidoc:643686:3/component/escidoc:644183/P437.PDF"/> - # + # - src= citation.find(linkspath) + vis= citation.find(visibility) + + visText="" + if vis is not None: + visText =vis.text + + + print vis + scr=None + + if visText != "private": + src= citation.find(linkspath) if src is not None: link=src.get("{http://www.w3.org/1999/xlink}href")