Fix radio widget onchange not being called when value is getting set

This commit is contained in:
Hadi Nategh 2020-05-08 15:22:28 +02:00
parent 319ae2637c
commit cf8f421c4d
2 changed files with 2 additions and 2 deletions

View File

@ -100,7 +100,7 @@ var et2_radiobox = /** @class */ (function (_super) {
et2_radiobox.prototype.set_value = function (_value) { et2_radiobox.prototype.set_value = function (_value) {
this.getRoot().iterateOver(function (radio) { this.getRoot().iterateOver(function (radio) {
if (radio.id == this.id) { if (radio.id == this.id) {
radio.input.prop('checked', _value == radio.options.set_value); radio.input.prop('checked', _value == radio.options.set_value).change();
} }
}, this, et2_radiobox); }, this, et2_radiobox);
}; };

View File

@ -124,7 +124,7 @@ class et2_radiobox extends et2_inputWidget
{ {
if (radio.id == this.id) if (radio.id == this.id)
{ {
radio.input.prop('checked', _value == radio.options.set_value); radio.input.prop('checked', _value == radio.options.set_value).change();
} }
}, this, et2_radiobox); }, this, et2_radiobox);
} }