[IMP]Interger/float widget returning its type related value.

bzr revid: vme@tinyerp.com-20121123064525-gghxxc2tdjx0hgbb
This commit is contained in:
Vidhin Mehta (OpenERP) 2012-11-23 12:15:25 +05:30
parent 2527b32ae7
commit e272ea66bd
1 changed files with 4 additions and 2 deletions

View File

@ -1924,7 +1924,8 @@ instance.web.search.ExtendedSearchProposition.Integer = instance.web.search.Exte
},
get_value: function() {
try {
return instance.web.parse_value(this.$el.val(), {'widget': 'integer'});
var val =this.$el.val();
return instance.web.parse_value(val == "" ? 0 : val, {'widget': 'integer'});
} catch (e) {
return "";
}
@ -1948,7 +1949,8 @@ instance.web.search.ExtendedSearchProposition.Float = instance.web.search.Extend
},
get_value: function() {
try {
return instance.web.parse_value(this.$el.val(), {'widget': 'float'});
var val =this.$el.val();
return instance.web.parse_value(val == "" ? 0.0 : val, {'widget': 'float'});
} catch (e) {
return "";
}