[Mpuls-commits] r457 - in wasko/trunk: . waskaweb/lib waskaweb/model waskaweb/templates/casemanagement/evaluation waskaweb/templates/logbook

scm-commit@wald.intevation.org scm-commit at wald.intevation.org
Thu Apr 2 09:24:46 CEST 2009


Author: torsten
Date: 2009-04-02 09:24:44 +0200 (Thu, 02 Apr 2009)
New Revision: 457

Modified:
   wasko/trunk/ChangeLog.txt
   wasko/trunk/waskaweb/lib/evaluation.py
   wasko/trunk/waskaweb/model/logbook.py
   wasko/trunk/waskaweb/templates/casemanagement/evaluation/evaluation_effort.mako
   wasko/trunk/waskaweb/templates/logbook/edit_body.mako
Log:
Fixed issue151


Modified: wasko/trunk/ChangeLog.txt
===================================================================
--- wasko/trunk/ChangeLog.txt	2009-04-01 14:06:48 UTC (rev 456)
+++ wasko/trunk/ChangeLog.txt	2009-04-02 07:24:44 UTC (rev 457)
@@ -1,3 +1,14 @@
+2009-04-02	Sascha L. Teichmann	<teichmann at intevation.de>
+
+	Fixed issue151:
+
+	* waskaweb/model/logbook.py,
+	  waskaweb/lib/evaluation.py,
+	  waskaweb/templates/logbook/edit_body.mako,
+	  waskaweb/templates/casemanagement/evaluation/evaluation_effort.mako:
+	  Added new option "Teambesprechung". Adjusted evaluation on logbook
+	  page. 
+
 2009-04-01	Sascha L. Teichmann	<teichmann at intevation.de>
 
 	* waskaweb/converter/wasko_v1v2.py: Fixed elimination of

Modified: wasko/trunk/waskaweb/lib/evaluation.py
===================================================================
--- wasko/trunk/waskaweb/lib/evaluation.py	2009-04-01 14:06:48 UTC (rev 456)
+++ wasko/trunk/waskaweb/lib/evaluation.py	2009-04-02 07:24:44 UTC (rev 457)
@@ -879,6 +879,7 @@
                    '14': [0,0],
                    '15': [0,0],
                    '16': [0,0],
+                   '17': [0,0],
                    'sum_cat1': [0,0],
                    'sum_cat2': [0,0],
                    'sum_cat3': [0,0],
@@ -922,7 +923,7 @@
                     if type in ['9', '10', '11', '12', '13', '14']:
                         result['sum_cat3'][0] += num
                         result['sum_cat3'][1] += int(duration)
-                    if type in ['15', '16', '-2']:
+                    if type in ['15', '16', '17', '-2']:
                         result['sum_cat4'][0] += num
                         result['sum_cat4'][1] += int(duration)
                     if type in ['-1']:
@@ -1011,12 +1012,12 @@
         Evaluation.__init__(self, compressed_ids)
         self.export_label = _('cm_eval_header_effort')
         self.export_eval_what = u"alle Jugendliche"
-        self.sql  = """SELECT sum(l.dauer) AS dauer, count(l.dauer) AS anzahl, l.art, m.id
+        self.sql  = """SELECT sum(coalesce(l.dauer, '0 second'::interval)) AS dauer, count(l.id) AS anzahl, l.art, m.id
             FROM ka_logbuch_tbl_view l
             JOIN master_tbl_eval_total_view m
             ON m.id = l.master_id
-            WHERE %s 
-            AND l.dauer IS NOT NULL 
+            WHERE %s
+            AND l.art <> '0'
             GROUP BY l.art, m.id 
             ORDER BY l.art
         """ % self.where_clause(self.compressed_ids, "l.master_id")

Modified: wasko/trunk/waskaweb/model/logbook.py
===================================================================
--- wasko/trunk/waskaweb/model/logbook.py	2009-04-01 14:06:48 UTC (rev 456)
+++ wasko/trunk/waskaweb/model/logbook.py	2009-04-02 07:24:44 UTC (rev 457)
@@ -52,6 +52,7 @@
       "14": u'Förder bzw. Fallkonferenz',
       "15": u'Fahrtwege',
       "16": u'Dokumentation WASKO',
+      "17": u'Teambesprechung',
       "-2": u'sonstige Angaben',
       "-1": u'Keine Angabe'}
 

Modified: wasko/trunk/waskaweb/templates/casemanagement/evaluation/evaluation_effort.mako
===================================================================
--- wasko/trunk/waskaweb/templates/casemanagement/evaluation/evaluation_effort.mako	2009-04-01 14:06:48 UTC (rev 456)
+++ wasko/trunk/waskaweb/templates/casemanagement/evaluation/evaluation_effort.mako	2009-04-02 07:24:44 UTC (rev 457)
@@ -67,6 +67,9 @@
     <td style="padding-left:1em;">Dokumentation WASKO</td><td class="num">${c.eval_effort['16'][0]}</td><td class="num">${c.eval_effort['16'][1]}</td>
   </tr>
   <tr class="table_row_v_12">
+    <td style="padding-left:1em;">Teambesprechung</td><td class="num">${c.eval_effort['17'][0]}</td><td class="num">${c.eval_effort['17'][1]}</td>
+  </tr>
+  <tr class="table_row_v_12">
     <td style="padding-left:1em;">Sonstige Angaben</td><td class="num">${c.eval_effort['-2'][0]}</td><td class="num">${c.eval_effort['-2'][1]}</td>
   </tr>
   <tr>

Modified: wasko/trunk/waskaweb/templates/logbook/edit_body.mako
===================================================================
--- wasko/trunk/waskaweb/templates/logbook/edit_body.mako	2009-04-01 14:06:48 UTC (rev 456)
+++ wasko/trunk/waskaweb/templates/logbook/edit_body.mako	2009-04-02 07:24:44 UTC (rev 457)
@@ -58,6 +58,7 @@
     <optgroup label="Sonstiges">
       <option value="15">Fahrtwege</option>
       <option value="16">Dokumentation WASKO</option>
+      <option value="17">Teambesprechung</option>
       <option value="-2">sonstige Angaben</option>
       <option value="-1">Keine Angabe</option>
     </optgroup>



More information about the Mpuls-commits mailing list