[Mpuls-commits] r5674 - base/trunk/mpulsweb/templates/casemanagement

scm-commit@wald.intevation.org scm-commit at wald.intevation.org
Wed Nov 30 14:43:23 CET 2011


Author: ludwig
Date: 2011-11-30 14:43:22 +0100 (Wed, 30 Nov 2011)
New Revision: 5674

Modified:
   base/trunk/mpulsweb/templates/casemanagement/caselist.mako
Log:
Issue 2716: Editing of cases marked for deletion is excluded from the caselist. 


Modified: base/trunk/mpulsweb/templates/casemanagement/caselist.mako
===================================================================
--- base/trunk/mpulsweb/templates/casemanagement/caselist.mako	2011-11-30 13:37:51 UTC (rev 5673)
+++ base/trunk/mpulsweb/templates/casemanagement/caselist.mako	2011-11-30 13:43:22 UTC (rev 5674)
@@ -103,7 +103,8 @@
   % endif
   % for title, urlpart, style, roles, get_value in fields:
     % if h.hasRole(roles):
-      % if case.getState().getState() != 5:
+      % if case.getState().getState() != 5 and case.getState().getState() != 3:
+        
         <td><a href="${h.url_for(controller='/case', action='select',
                                  id=case.id, confirmed=0)}">${get_value(case) | F.NA}</a></td>
       % else:
@@ -209,17 +210,17 @@
 </%def>
 
 <%def name="get_actions(case)">
-  % if case.getState().getState() != 5:
-    <a href="${h.url_for(controller='case', action='select', id=case.id,
-                         confirmed=0)}">
+  % if h.hasRole(['admin']):
+    % if case.getState().getState() != 5:
+      <a href="${h.url_for(controller='case', action='select', id=case.id,
+	     		 confirmed=0)}">
       <img src    = "${h.url_for('/images/icons/open_active_22.png')}"
-           border = "0"
-           alt    = "${_('Show')}"
-           title  = "${_('Show')}"
-           width  = "22"
-           height = "22"></a>
-  % endif
-  % if h.hasRole(['admin']):
+	   border = "0"
+	   alt    = "${_('Show')}"
+	   title  = "${_('Show')}"
+	   width  = "22"
+	   height = "22"></a>
+    % endif
     % if case.getState().getState() in (3, 5):
       <a href="${h.url_for(controller='case', action='delete', id=case.id,
                            confirmed=0)}">
@@ -253,6 +254,16 @@
              height = "22"></a>
     % endif
   % elif h.hasRole(['cm']) and case.getState().getState() in (1, 2):
+    % if case.getState().getState() != 5 and  case.getState().getState() != 4:
+      <a href="${h.url_for(controller='case', action='select', id=case.id,
+	     		 confirmed=0)}">
+      <img src    = "${h.url_for('/images/icons/open_active_22.png')}"
+	   border = "0"
+	   alt    = "${_('Show')}"
+	   title  = "${_('Show')}"
+	   width  = "22"
+	   height = "22"></a>
+    % endif
     % if g.mpuls_config.is_enabled('case-module', 'anonymize'):
       <a href="${h.url_for(controller='case', 
                            action='markForAnonymizeFromOverview', id=case.id,



More information about the Mpuls-commits mailing list