o: ActiveSupport::Cache::Entry :@compressedF:@expires_in0:@created_atf1416672643.227178: @value" {I" class:ETI"ProcessedAsset;FI"logical_path;TI"9locomotive/views/content_entries/_popup_form_view.js;FI" pathname;TI"¤/Users/didier/.rbenv/versions/2.1.3/lib/ruby/gems/2.1.0/gems/locomotive_cms-2.5.5/app/assets/javascripts/locomotive/views/content_entries/_popup_form_view.js.coffee;FI"content_type;TI"application/javascript;TI" mtime;TI"2014-11-22T16:47:36+01:00;TI" length;Ti6I" digest;TI"%1c109ee9752c8b123980b42d7aaa80c8;FI" source;TI"6(function() { var _base, __bind = function(fn, me){ return function(){ return fn.apply(me, arguments); }; }, __hasProp = {}.hasOwnProperty, __extends = function(child, parent) { for (var key in parent) { if (__hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; }; (_base = Locomotive.Views).ContentEntries || (_base.ContentEntries = {}); Locomotive.Views.ContentEntries.PopupFormView = (function(_super) { __extends(PopupFormView, _super); function PopupFormView() { this.reset = __bind(this.reset, this); return PopupFormView.__super__.constructor.apply(this, arguments); } PopupFormView.prototype.initialize = function() { this.create_dialog(); return PopupFormView.__super__.initialize.call(this); }; PopupFormView.prototype.render = function() { PopupFormView.__super__.render.call(this); return this; }; PopupFormView.prototype.save = function(event) { this.touch_richtexteditor(); return this.save_in_ajax(event, { headers: { 'X-Flash': true }, on_success: (function(_this) { return function(response, xhr) { var entry; entry = new Locomotive.Models.ContentEntry(JSON.parse(xhr.responseText)); _this.options.parent_view.insert_or_update_entry(entry); return _this.close(); }; })(this) }); }; PopupFormView.prototype.create_dialog = function() { return this.dialog = $(this.el).dialog({ autoOpen: false, modal: true, dialogClass: 'content-entry-popup', zIndex: window.application_view.unique_dialog_zindex(), width: 770, create: (function(_this) { return function(event, ui) { var actions; $(_this.el).prev().find('.ui-dialog-title').html(_this.$('h2').html()); _this.$('h2').remove(); actions = _this.$('.dialog-actions').appendTo($(_this.el).parent()).addClass('ui-dialog-buttonpane ui-widget-content ui-helper-clearfix'); actions.find('#close-link').click(function(event) { return _this.close(event); }); return actions.find('input[type=submit]').click(function(event) { var $buttons_pane, $form; $form = _this.$el.find('form'); $buttons_pane = $(event.target).parent(); $.rails.disableFormElements($buttons_pane); return $form.trigger('submit').bind('ajax:complete', function() { return $.rails.enableFormElements($buttons_pane); }); }); }; })(this), open: (function(_this) { return function(event, ui, extra) { return $(_this.el).dialog('overlayEl').bind('click', function() { return _this.close(); }); }; })(this) }); }; PopupFormView.prototype.open = function() { var parent_el; parent_el = $(this.el).parent(); if (this.model.isNew()) { parent_el.find('.edit-section').hide(); parent_el.find('.new-section').show(); } else { parent_el.find('.new-section').hide(); parent_el.find('.edit-section').show(); } this.clear_errors(); return $(this.el).dialog('open'); }; PopupFormView.prototype.close = function(event) { if (event != null) { event.stopPropagation() & event.preventDefault(); } this.clear_errors(); $(this.el).dialog('overlayEl').unbind('click'); return $(this.el).dialog('close'); }; PopupFormView.prototype.center = function() { return $(this.el).dialog('option', 'position', 'center'); }; PopupFormView.prototype.reset = function(entry) { this.model.reset_attributes(); this.model.set(entry.attributes); if (entry.isNew()) { this.model.id = null; return PopupFormView.__super__.reset.call(this); } else { return this.refresh(); } }; PopupFormView.prototype.slugify_label_field = function() {}; PopupFormView.prototype.enable_has_many_fields = function() {}; PopupFormView.prototype.enable_many_to_many_fields = function() {}; PopupFormView.prototype.touch_richtexteditor = function() { return _.each(this.$('li.input.rte textarea.html'), (function(_this) { return function(textarea) { return $(textarea).tinymce().save(); }; })(this)); }; PopupFormView.prototype.tinyMCE_settings = function() { return window.Locomotive.tinyMCE.popupSettings; }; return PopupFormView; })(Locomotive.Views.ContentEntries.FormView); }).call(this); ;TI"dependency_digest;TI"%d95699d71a7edd8d5cbba8e0ed95f087;FI"required_paths;T[I"”/Users/didier/.rbenv/versions/2.1.3/lib/ruby/gems/2.1.0/gems/locomotive_cms-2.5.5/app/assets/javascripts/locomotive/views/shared/form_view.js.coffee;FI"¤/Users/didier/.rbenv/versions/2.1.3/lib/ruby/gems/2.1.0/gems/locomotive_cms-2.5.5/app/assets/javascripts/locomotive/views/content_entries/_popup_form_view.js.coffee;FI"dependency_paths;T[{I" path;TI"¤/Users/didier/.rbenv/versions/2.1.3/lib/ruby/gems/2.1.0/gems/locomotive_cms-2.5.5/app/assets/javascripts/locomotive/views/content_entries/_popup_form_view.js.coffee;FI" mtime;TI"2014-11-22T16:47:36+01:00;TI" digest;TI"%61c03183c90f5cbed637915f1acf6691;F{@I"”/Users/didier/.rbenv/versions/2.1.3/lib/ruby/gems/2.1.0/gems/locomotive_cms-2.5.5/app/assets/javascripts/locomotive/views/shared/form_view.js.coffee;F@ I"2014-11-22T16:47:36+01:00;T@"I"%6b625a8f368e04b11585748da811b133;FI" _version;TI"%ffd318ca8b794f42f5029101c2cf5d91;F