[IMP] Selection field with placeholder feature.
bzr revid: tta@openerp.com-20121105094602-v2a4z4m4mighxgqw
This commit is contained in:
parent
df41b0ef2d
commit
dd12cbe1b6
|
@ -993,6 +993,7 @@
|
|||
<span class="oe_form_field oe_datepicker_root oe_form_field_datetime" t-att-style="widget.node.attrs.style"/>
|
||||
</t>
|
||||
<t t-name="FieldSelection">
|
||||
<t t-set="placeholder" t-value="! widget.get('effective_readonly') ? widget.node.attrs.placeholder : ''"/>
|
||||
<span class="oe_form_field oe_form_field_selection" t-att-style="widget.node.attrs.style">
|
||||
<select t-if="!widget.get('effective_readonly')"
|
||||
t-att-name="widget.name"
|
||||
|
@ -1000,7 +1001,7 @@
|
|||
t-att-autofocus="widget.node.attrs.autofocus"
|
||||
t-att-id="widget.id_for_label">
|
||||
<t t-foreach="widget.values" t-as="option">
|
||||
<option><t t-esc="option[1]"/></option>
|
||||
<option><t t-esc="placeholder" t-if="option[0] == false"/><t t-esc="option[1]" t-if="option[0] != false"/></option>
|
||||
</t>
|
||||
</select>
|
||||
</span>
|
||||
|
|
Loading…
Reference in New Issue