app/assets/javascripts/jqr-helpers.js in jqr-helpers-1.0.53 vs app/assets/javascripts/jqr-helpers.js in jqr-helpers-1.0.54
- old
+ new
@@ -193,9 +193,15 @@
metadata_input += '<input name="' + csrf_param + '" value="' +
csrf_token + '" type="hidden" />';
}
form.hide().append(metadata_input).appendTo('body');
+ if ($(element).data('params')) {
+ $.each($(element).data('params'), function(name, value) {
+ form.append("<input type='hidden' name='" + name +
+ "' value='" + value + "'/>");
+ });
+ }
$(form).data(element.data()); // copy to form
$(form).data('remote', true);
$(form).addClass('ujs-ajax');
$(form).data('real-element', element.attr('id'));
form.submit();