[Mpuls-commits] r2809 - in base/trunk: . mpulsweb/model
scm-commit@wald.intevation.org
scm-commit at wald.intevation.org
Fri May 28 20:48:41 CEST 2010
Author: bh
Date: 2010-05-28 20:48:40 +0200 (Fri, 28 May 2010)
New Revision: 2809
Modified:
base/trunk/ChangeLog
base/trunk/mpulsweb/model/phase.py
Log:
* mpulsweb/model/phase.py (Field.get_link): Use the tag function
to generate tags with attributes.
Modified: base/trunk/ChangeLog
===================================================================
--- base/trunk/ChangeLog 2010-05-28 18:46:43 UTC (rev 2808)
+++ base/trunk/ChangeLog 2010-05-28 18:48:40 UTC (rev 2809)
@@ -1,5 +1,10 @@
2010-05-28 Bernhard Herzog <bh at intevation.de>
+ * mpulsweb/model/phase.py (Field.get_link): Use the tag function
+ to generate tags with attributes.
+
+2010-05-28 Bernhard Herzog <bh at intevation.de>
+
* mpulsweb/controllers/evaluate.py (get_phasesuccessors): New.
Moved here from helpers.
Modified: base/trunk/mpulsweb/model/phase.py
===================================================================
--- base/trunk/mpulsweb/model/phase.py 2010-05-28 18:46:43 UTC (rev 2808)
+++ base/trunk/mpulsweb/model/phase.py 2010-05-28 18:48:40 UTC (rev 2809)
@@ -10,6 +10,7 @@
from formed.instance.backends.common import RuleEvalContext
from formed.instance.tree import InstanceLeaf, PageInstanceNode, RepeatInstanceContainerNode
+from mpulsweb.lib.helpers import tag
from mpulsweb.lib.db import PostgresDBInterface
@@ -363,8 +364,10 @@
out = []
style = self.is_ok() and "ok" or "error"
element_id = ":".join(self.id.split(':')[1:])
- out.append('<a class="%s" href="/formularpage/select/%s:%s#%s:%s">'
- % (style, self.page, element_id, self.name, element_id))
+ out.append(tag("a", class_=style,
+ href=("/formularpage/select/%s:%s#%s:%s"
+ % (self.page, element_id, self.name,
+ element_id))))
out.append('%s' % self.label)
out.append('</a>')
return "".join(out)
More information about the Mpuls-commits
mailing list