Sha256: a89c79a349245328b115d5ea642c39976843e42f4052d70c11619ad5494d042b

Contents?: true

Size: 489 Bytes

Versions: 8

Compression:

Stored size: 489 Bytes

Contents

// extracts form data from an existing rails form, and replaces it's own contents with the contents
// of data
jQuery.fn.addSauceFromForm = function(data) {
  var formData = $(data).find(".ui-dialog-content").children();
  var formToken = $(data).find("input[name='authenticity_token']");
  var formMethod = $(data).find("input[name='_method']");
	$(data).children().remove();
  $(data).append(formData);
  $(data).append(formToken);
  $(data).append(formMethod);
	$(this).append(data);
};

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
kosmas58-compass-jquery-plugin-0.1.8.1 templates/secret_sauce/secret_sauce.js
kosmas58-compass-jquery-plugin-0.1.8.2 templates/secret_sauce/secret_sauce.js
kosmas58-compass-jquery-plugin-0.1.8 templates/secret_sauce/secret_sauce.js
kosmas58-compass-jquery-plugin-0.2.0.1 templates/secret_sauce/secret_sauce.js
kosmas58-compass-jquery-plugin-0.2.0.3 templates/secret_sauce/secret_sauce.js
kosmas58-compass-jquery-plugin-0.2.0 templates/secret_sauce/secret_sauce.js
kosmas58-compass-jquery-plugin-0.2.2.0 templates/secret_sauce/secret_sauce.js
kosmas58-compass-jquery-plugin-0.2.2.2 templates/secret_sauce/secret_sauce.js