mirror of
https://github.com/Combodo/iTop.git
synced 2026-02-13 07:24:13 +01:00
Custom fields: not all the values were correctly recorded (event name collision)
SVN:trunk[3946]
This commit is contained in:
@@ -1950,7 +1950,7 @@ EOF
|
||||
$oPage->add_ready_script("$('#{$iId}_console_form').console_form_handler('alignColumns');");
|
||||
$oPage->add_ready_script("$('#{$iId}_console_form').console_form_handler('option', 'field_set', $('#{$iId}_field_set'));");
|
||||
// field_change must be processed to refresh the hidden value at anytime
|
||||
$oPage->add_ready_script("$('#{$iId}_console_form .field_set').bind('field_change', function() { $('#{$iId}').val(JSON.stringify($('#{$iId}_field_set').triggerHandler('get_current_values'))); });");
|
||||
$oPage->add_ready_script("$('#{$iId}_console_form').bind('value_change', function() { $('#{$iId}').val(JSON.stringify($('#{$iId}_field_set').triggerHandler('get_current_values'))); });");
|
||||
// update_value is triggered when preparing the wizard helper object for ajax calls
|
||||
$oPage->add_ready_script("$('#{$iId}').bind('update_value', function() { $(this).val(JSON.stringify($('#{$iId}_field_set').triggerHandler('get_current_values'))); });");
|
||||
// validate is triggered by CheckFields, on all the input fields, once at page init and once before submitting the form
|
||||
|
||||
@@ -99,7 +99,8 @@ class ConsoleSimpleFieldRenderer extends FieldRenderer
|
||||
id: $(me).attr("id"),
|
||||
name: $(me).closest(".form_field").attr("data-field-id"),
|
||||
value: $(me).val()
|
||||
});
|
||||
})
|
||||
.closest('.form_handler').trigger('value_change');
|
||||
});
|
||||
EOF
|
||||
);
|
||||
@@ -114,7 +115,8 @@ EOF
|
||||
id: $(me).attr("id"),
|
||||
name: $(me).closest(".form_field").attr("data-field-id"),
|
||||
value: $(me).val()
|
||||
});
|
||||
})
|
||||
.closest('.form_handler').trigger('value_change');
|
||||
});
|
||||
EOF
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user