[FIX] web: view_form.js: radio buttons bug fix

Clicking on a checked radio button doesn't uncheck it anymore
This commit is contained in:
Aaron Bohy 2014-12-19 11:44:28 +01:00
parent 8de7be6219
commit 3505dcce70
1 changed files with 1 additions and 3 deletions

View File

@ -3215,9 +3215,7 @@ instance.web.form.FieldRadio = instance.web.form.AbstractField.extend(instance.w
click_change_value: function (event) {
var val = $(event.target).val();
val = this.field.type == "selection" ? val : +val;
if (val == this.get_value()) {
this.set_value(false);
} else {
if (val !== this.get_value()) {
this.set_value(val);
}
},