[Mpuls-commits] r334 - in wasko/trunk: . waskaweb/lib waskaweb/templates/casemanagement

scm-commit@wald.intevation.org scm-commit at wald.intevation.org
Thu Mar 5 13:15:59 CET 2009


Author: teichmann
Date: 2009-03-05 13:15:55 +0100 (Thu, 05 Mar 2009)
New Revision: 334

Modified:
   wasko/trunk/ChangeLog.txt
   wasko/trunk/waskaweb/lib/xmlexport.py
   wasko/trunk/waskaweb/templates/casemanagement/downloadXML.mako
Log:
Set version of XML files to 2


Modified: wasko/trunk/ChangeLog.txt
===================================================================
--- wasko/trunk/ChangeLog.txt	2009-03-05 09:45:45 UTC (rev 333)
+++ wasko/trunk/ChangeLog.txt	2009-03-05 12:15:55 UTC (rev 334)
@@ -1,3 +1,12 @@
+2009-03-05	Sascha L. Teichmann	<teichmann at intevation.de>
+
+	* waskaweb/lib/xmlexport.py: Set version of XML files to 2
+
+	* waskaweb/templates/casemanagement/downloadXML.mako: If
+	  more than one case is selected for export add hint that doing
+	  so will result in files which are not able to be processed 
+	  by the Offline Client.
+
 2009-03-05	Torsten Irlaender  <torsten.irlaender at intevation.de> 
 
 	* waskaweb/public/styles/all.css,

Modified: wasko/trunk/waskaweb/lib/xmlexport.py
===================================================================
--- wasko/trunk/waskaweb/lib/xmlexport.py	2009-03-05 09:45:45 UTC (rev 333)
+++ wasko/trunk/waskaweb/lib/xmlexport.py	2009-03-05 12:15:55 UTC (rev 334)
@@ -35,7 +35,9 @@
 import xml.utils.iso8601 as iso8601
 from   time import mktime
 
+VERSION = 2
 
+
 from pylons import g
 
 import waskaweb.lib.helpers as h
@@ -273,7 +275,7 @@
     selector = selectFactory.createSelector()
 
     out.write('<?xml version="1.0" encoding="UTF-8"?>\n')
-    out.write("<cases>")
+    out.write('<cases version="%d">' % VERSION)
     for mid in ids:
         case = ExportCase(mid, selector)
         case.fetchData(cur)

Modified: wasko/trunk/waskaweb/templates/casemanagement/downloadXML.mako
===================================================================
--- wasko/trunk/waskaweb/templates/casemanagement/downloadXML.mako	2009-03-05 09:45:45 UTC (rev 333)
+++ wasko/trunk/waskaweb/templates/casemanagement/downloadXML.mako	2009-03-05 12:15:55 UTC (rev 334)
@@ -19,6 +19,16 @@
 Ihnen obliegt somit die Einhaltung der jeweiligen Datenschutzbestimmungen.
 </p>
 
+<% case_bundle = session.get('casebundle') %>
+% if case_bundle and len(case_bundle.case_list) > 1:
+    <p class="import_p">
+    <strong>Hinweis:</strong> Sie haben mehr als eine Akte ausgewählt.
+    Die so erzeugte Datei kann z.Z. nicht vom Offline-Klienten verarbeitet
+    werden. Wenn Sie eine Datei im Offline-Klienten weiterverarbeiten wollen,
+    dürfen Sie nur eine Akte auswählen.
+    </p>
+% endif
+
 <div class="import_box_dialog">
 
     <p class="import_p">



More information about the Mpuls-commits mailing list