diff options
| author | Christophe Matthieu <chm@openerp.com> | 2013-04-11 11:06:54 +0200 |
|---|---|---|
| committer | Christophe Matthieu <chm@openerp.com> | 2013-04-11 11:06:54 +0200 |
| commit | 67452d290eac4e26a0d940510960e2cdc36c657b (patch) | |
| tree | bce80a7d6574c5ca0f55d46dd751693b90e288c2 /addons/web/static/src/xml/base.xml | |
| parent | f2beb97168c474b11b80eff24cab7ff4a450a2ab (diff) | |
[IMP] view_form: radio button: change style for required field
bzr revid: chm@openerp.com-20130411090654-ujf7fio6lnsppv90
Diffstat (limited to 'addons/web/static/src/xml/base.xml')
| -rw-r--r-- | addons/web/static/src/xml/base.xml | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/addons/web/static/src/xml/base.xml b/addons/web/static/src/xml/base.xml index df289bbb2ea..d57dc2107f5 100644 --- a/addons/web/static/src/xml/base.xml +++ b/addons/web/static/src/xml/base.xml @@ -1112,7 +1112,7 @@ </span> </t> <t t-name="FieldRadio"> - <span t-attf-class="oe_form_field oe_form_field_radio #{widget.horizontal ? 'oe_horizontal' : 'oe_vertical'}" t-att-style="widget.node.attrs.style"> + <span t-attf-class="oe_form_field oe_form_field_radio #{widget.horizontal ? 'oe_horizontal' : 'oe_vertical'} #{widget.field.required or widget.node.attrs.required ? 'oe_required' : ''}" t-att-style="widget.node.attrs.style"> <span class="oe_radio_edit_only"> <t t-if="widget.horizontal"> <t t-set="width" t-value="Math.floor(100 / widget.selection.length)"/> @@ -1123,13 +1123,15 @@ <br/> </t> <t t-foreach="widget.selection" t-as="selection"> - <input type="radio" t-att-name="widget.uniqueId" t-att-id="widget.uniqueId + '_' + selection[0]" t-att-style="'width: ' + width + '%;'" t-att-value="selection[0]"/> + <div t-att-style="'width: ' + width + '%;'"> + <span class="oe_radio_input"><input type="radio" t-att-name="widget.uniqueId" t-att-id="widget.uniqueId + '_' + selection[0]" t-att-value="selection[0]"/></span> + </div> </t> </t> <t t-if="!widget.horizontal"> <t t-foreach="widget.selection" t-as="selection"> - <div t-att-data-id="selection[0]"> - <input type="radio" t-att-id="widget.uniqueId + '_' + selection[0]" t-att-name="widget.uniqueId" t-att-value="selection[0]"/>&nbsp;<label t-if="!widget.no_radiolabel" t-att-for="widget.uniqueId + '_' + selection[0]"><t t-esc="selection[1]"/></label> + <div> + <span class="oe_radio_input"><input type="radio" t-att-id="widget.uniqueId + '_' + selection[0]" t-att-name="widget.uniqueId" t-att-value="selection[0]"/></span><label t-if="!widget.no_radiolabel" t-att-for="widget.uniqueId + '_' + selection[0]"><t t-esc="selection[1]"/></label> </div> </t> </t> |
