o: ActiveSupport::Cache::Entry :@compressedF:@created_atf1354144995.467894:@expires_in0: @value"{I" class:EFI"ProcessedAsset;FI"logical_path;FI"jquery.remotipart.js;TI" pathname;FI"v/Users/fredwu/.rvm/gems/ruby-1.9.3-p327-perf/gems/remotipart-1.0.2/vendor/assets/javascripts/jquery.remotipart.js;TI"content_type;FI"application/javascript;FI" mtime;FI"2012-11-29T10:22:29+11:00;FI" length;Fi4 I" digest;F"%05deea073a5b0c28eeee58abbc2e454cI" source;FI"4 (function($) { var remotipart; $.remotipart = remotipart = { setup: function(form) { form // Allow setup part of $.rails.handleRemote to setup remote settings before canceling default remote handler // This is required in order to change the remote settings using the form details .one('ajax:beforeSend.remotipart', function(e, xhr, settings){ // Delete the beforeSend bindings, since we're about to re-submit via ajaxSubmit with the beforeSubmit // hook that was just setup and triggered via the default `$.rails.handleRemote` // delete settings.beforeSend; delete settings.beforeSend; settings.iframe = true; settings.files = $($.rails.fileInputSelector, form); settings.data = form.serializeArray(); settings.processData = false; // Modify some settings to integrate JS request with rails helpers and middleware if (settings.dataType === undefined) { settings.dataType = 'script *'; } settings.data.push({name: 'remotipart_submitted', value: true}); // Allow remotipartSubmit to be cancelled if needed if ($.rails.fire(form, 'ajax:remotipartSubmit', [xhr, settings])) { // Second verse, same as the first $.rails.ajax(settings); } //Run cleanup remotipart.teardown(form); // Cancel the jQuery UJS request return false; }) // Keep track that we just set this particular form with Remotipart bindings // Note: The `true` value will get over-written with the `settings.dataType` from the `ajax:beforeSend` handler .data('remotipartSubmitted', true); }, teardown: function(form) { form .unbind('ajax:beforeSend.remotipart') .removeData('remotipartSubmitted') } }; $('form').live('ajax:aborted:file', function(){ var form = $(this); remotipart.setup(form); // If browser does not support submit bubbling, then this live-binding will be called before direct // bindings. Therefore, we should directly call any direct bindings before remotely submitting form. if (!$.support.submitBubbles && $().jquery < '1.7' && $.rails.callFormSubmitBindings(form) === false) return $.rails.stopEverything(e); // Manually call jquery-ujs remote call so that it can setup form and settings as usual, // and trigger the `ajax:beforeSend` callback to which remotipart binds functionality. $.rails.handleRemote(form); return false; }); })(jQuery); ;FI"dependency_digest;F"%292d0e241aa2f5f5f915e375da5588a7I"required_paths;F[I"|/Users/fredwu/.rvm/gems/ruby-1.9.3-p327-perf/gems/remotipart-1.0.2/vendor/assets/javascripts/jquery.iframe-transport.js;TI"v/Users/fredwu/.rvm/gems/ruby-1.9.3-p327-perf/gems/remotipart-1.0.2/vendor/assets/javascripts/jquery.remotipart.js;TI"dependency_paths;F[{I" path;FI"v/Users/fredwu/.rvm/gems/ruby-1.9.3-p327-perf/gems/remotipart-1.0.2/vendor/assets/javascripts/jquery.remotipart.js;TI" mtime;FI"2012-11-29T10:22:29+11:00;FI" digest;F"%c9fcd77f860280e866c43805cd2a4d01{I" path;FI"|/Users/fredwu/.rvm/gems/ruby-1.9.3-p327-perf/gems/remotipart-1.0.2/vendor/assets/javascripts/jquery.iframe-transport.js;TI" mtime;FI"2012-11-29T10:22:29+11:00;FI" digest;F"%f45753f40f0237b53b1b80f35094cb33I" _version;F"%9f3b95dd7ea3030dc35985c0a8020862