Added custom radio input template
authorThierry Florac <thierry.florac@onf.fr>
Mon, 15 Sep 2014 13:04:12 +0200
changeset 58 cac3b20fae4c
parent 57 b9f706fc46b7
child 59 8c8d6e681c70
Added custom radio input template
src/ztfy/myams/templates/forms/radio-input.pt
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/ztfy/myams/templates/forms/radio-input.pt	Mon Sep 15 13:04:12 2014 +0200
@@ -0,0 +1,35 @@
+<div class="inline-group" i18n:domain="ztfy.myams">
+	<label class="radio"
+		   tal:repeat="item view/items">
+		<input type="radio"
+			   tal:define="checked item/checked"
+			   tal:attributes="id item/id;
+								name item/name;
+								class view/klass;
+								value item/value;
+								style view/style;
+								title view/title;
+								lang view/lang;
+								onclick view/onclick;
+								ondblclick view/ondblclick;
+								onmousedown view/onmousedown;
+								onmouseup view/onmouseup;
+								onmouseover view/onmouseover;
+								onmousemove view/onmousemove;
+								onmouseout view/onmouseout;
+								onkeypress view/onkeypress;
+								onkeydown view/onkeydown;
+								onkeyup view/onkeyup;
+								disabled view/disabled;
+								tabindex view/tabindex;
+								onfocus view/onfocus;
+								onblur view/onblur;
+								onchange view/onchange;
+								readonly view/readonly;
+								alt view/alt;
+								accesskey view/accesskey;
+								onselect view/onselect;
+								checked python: checked and 'checked' or None" />
+		<i></i><span tal:replace="item/label">Label</span>
+	</label>
+</div>