Sha256: 8374d898c383ef87e9c12ef87fc3fafb50e5a352bc50201acb5d8f92d85f165c
Contents?: true
Size: 1.98 KB
Versions: 12
Compression:
Stored size: 1.98 KB
Contents
o: ActiveSupport::Cache::Entry :@compressedF:@expires_in0:@created_atf1335887100.184674:@value"ƒ{I" class:EFI"ProcessedAsset; FI"logical_path; F"%active_admin/editor/quicksave.jsI" pathname; F"g/Users/ejholmes/Source/active_admin_editor/app/assets/javascripts/active_admin/editor/quicksave.jsI"content_type; FI"application/javascript; FI" mtime; FI"2012-05-01T08:43:42-07:00; FI"length; Fi8I"digest; F"%b5b4fa31f041018b0839865a242c91d6I"source; FI"8(function($) { $(function(){ var button = $('.button.quicksave'); button.click(function(e) { e.preventDefault(); $.ajaxSetup({ beforeSend: function(xhr) { xhr.setRequestHeader('X-CSRF-Token', $('meta[name="csrf-token"]').attr('content')); } }); var form = $(this).closest('form'); var url = form.attr('action'); var textarea = $(this).closest('.active_admin_editor').find('textarea'); var fields = textarea.attr('id').split('_'); var content = textarea.val(); var data = { _method: 'PUT' }; data[fields[0]] = {}; data[fields[0]][fields[1]] = content; $.ajax({ url: url, type: 'POST', dataType: 'json', data: data, success: function(response) { console.log('saved'); } }); }); }); })(jQuery); ; FI"dependency_digest; F"%7d6b3b025447780ffa7740a293fc839eI"required_paths; F["g/Users/ejholmes/Source/active_admin_editor/app/assets/javascripts/active_admin/editor/quicksave.jsI"dependency_paths; F[{I" path; F"g/Users/ejholmes/Source/active_admin_editor/app/assets/javascripts/active_admin/editor/quicksave.jsI" mtime; FI"2012-05-01T08:43:42-07:00; FI"digest; F"%b5b4fa31f041018b0839865a242c91d6I" _version; F"%aa7d0db7619379e13b08335dee027df2
Version data entries
12 entries across 12 versions & 1 rubygems