custom fields: Fix field value not saved on change, just after created.

Whenever custom fields templates get rendered within user account
settings, on-change event listener wasn't get created. Cause
event listener wasn't set properly.
This commit is contained in:
Yashashvi Dave
2018-05-10 18:42:46 +05:30
committed by Tim Abbott
parent 3703013b4f
commit ffe986886f

View File

@@ -328,7 +328,7 @@ exports.set_up = function () {
$("#deactivate_self_modal").modal("show");
});
$(".custom_user_field_value").on('change', function (e) {
$('#settings_page').on('change', '.custom_user_field_value', function (e) {
var fields = [];
var value = $(this).val();
fields.push({id: parseInt($(e.target).closest('.custom_user_field').attr("data-field-id"), 10),