[FIX] don't screw up typing of selection values in search view
bzr revid: xmo@openerp.com-20111006095301-98cda38m1y270f3m
This commit is contained in:
parent
69c6913915
commit
0fc5a423e3
|
@ -779,7 +779,7 @@ openerp.web.search.SelectionField = openerp.web.search.Field.extend(/** @lends o
|
|||
});
|
||||
},
|
||||
get_value: function () {
|
||||
return this.$element.val();
|
||||
return this.attrs.selection[parseInt(this.$element.val(), 10)][0];
|
||||
}
|
||||
});
|
||||
openerp.web.search.BooleanField = openerp.web.search.SelectionField.extend(/** @lends openerp.web.search.BooleanField# */{
|
||||
|
|
|
@ -1096,10 +1096,10 @@
|
|||
<t t-foreach="attrs.selection" t-as="option">
|
||||
<t t-set="selected" t-value="defaults[attrs.name] === option[0]"/>
|
||||
<option t-if="selected"
|
||||
t-att-value="option[0]" selected="selected">
|
||||
t-att-value="option_index" selected="selected">
|
||||
<t t-esc="option[1]"/>
|
||||
</option>
|
||||
<option t-if="!selected" t-att-value="option[0]">
|
||||
<option t-if="!selected" t-att-value="option_index">
|
||||
<t t-esc="option[1]"/>
|
||||
</option>
|
||||
</t>
|
||||
|
|
Loading…
Reference in New Issue