changeset 38:3c98cc79dd14

version 0.1 mit publicationen von pubman (TEST!!)
author dwinter
date Fri, 26 Apr 2013 19:09:50 +0200
parents 9b38ba45773b
children bbad6a092861 955d102392db
files MPIWGStaff.py zpt/staff/member_index_html.zpt
diffstat 2 files changed, 22 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/MPIWGStaff.py	Fri Apr 26 17:19:08 2013 +0200
+++ b/MPIWGStaff.py	Fri Apr 26 19:09:50 2013 +0200
@@ -1120,7 +1120,13 @@
         
         return tmp
     
-    
+    def getPublications(self,memberID="renn"):
+        
+        try:
+            pubs=self.mpiwgPubman.getPublications(memberID)
+            return pubs
+        except:
+            return []
 def manage_addMPIWGStaffFolderForm(self):
     """form for adding the project"""
     pt=PageTemplateFile('zpt/addMPIWGStaffFolderForm', globals()).__of__(self)
@@ -1519,6 +1525,7 @@
                 self.executeZSQL(query)
 
             
+
     
    
     def deleteField(self,REQUEST):
@@ -1547,6 +1554,11 @@
         splitted = ident.split("@");
         return splitted[0]
         
+    def getPublications(self):
+        
+        pubs= self.folder.getPublications("")
+       
+        return pubs
         
         
 InitializeClass(MPIWGStaffMember) 
--- a/zpt/staff/member_index_html.zpt	Fri Apr 26 17:19:08 2013 +0200
+++ b/zpt/staff/member_index_html.zpt	Fri Apr 26 19:09:50 2013 +0200
@@ -46,12 +46,20 @@
     <tal:block tal:define="publications python:here.ZDBInlineSearch(_table='publications',key_main=key,_op_key_main='eq',publish='yes')"
       tal:condition="publications">
       <h2>Selected publications</h2>
-      <p tal:repeat="publication python:member.sortBibliography(publications,content.publications_sort,max=5)">
+      <!--<p tal:repeat="publication python:member.sortBibliography(publications,content.publications_sort,max=5)">
         <a tal:omit-tag="not:publication/link" tal:attributes="href publication/link"
           tal:content="structure python:here.formatBibliography(here,publication)" />
       </p>
       <p tal:condition="python:len(publications)>5">
         <a class="internal" tal:attributes="href string:$baseUrl/publications_full">more</a>
+      </p>-->
+      
+      <p tal:repeat="publication python:member.getPublications()">
+        <a
+          tal:content="structure python:publication" />
+      </p>
+      <p tal:condition="python:len(publications)>5">
+        <a class="internal" tal:attributes="href string:$baseUrl/publications_full">more</a>
       </p>
     </tal:block>
     <!-- Talks -->