Sha256: a160520073f4adc8868dca63e6661c70e5ac86ffffce0459bcf1a97631e24cc3

Contents?: true

Size: 1.2 KB

Versions: 8

Compression:

Stored size: 1.2 KB

Contents

<%
  page_title = Typus::I18n.t("Edit %{resource}", :resource => @resource.model_name.human)
  title(page_title)
%>

<% content_for :main_grid do %>
  <h2>
    <%= page_title %>
    <small><%= list_actions %></small>
  </h2>

  <% if headless_mode? && params[:action] == 'edit' && flash.keys.include?(:notice) && !params[:_input] %>
    <script type="text/javascript">
      $(document).ready(function () {
        <% if params[:attribute] %>
          var option = new Option("<%= @item.to_label %>", "<%= @item.id %>", true, true);
          parent.$("#<%= params[:attribute] %>").append(option);
          parent.$(".chzn-select-<%= params[:attribute] %>").trigger("liszt:updated");
        <% else %>
          parent.Typus.parent_location_reload = true;
        <% end %>
        parent.$.fancybox.close();
      });
    </script>
  <% end %>

  <%= display_flash_message %>
  <%= render 'edit' %>

  <% locals = { :options => params.dup.cleanup.merge!(:action => 'update') } %>
  <%= render 'form', locals %>

  <%= typus_relationships unless headless_mode? %>
<% end %>

<div class="grid_2">
  <%= build_sidebar || render("admin/templates/profile_sidebar") %>
</div>

<div class="grid_8">
  <%= yield :main_grid %>
</div>

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
typus-3.1.10 app/views/admin/resources/edit.html.erb
typus-3.1.9 app/views/admin/resources/edit.html.erb
typus-3.1.8 app/views/admin/resources/edit.html.erb
typus-3.1.7 app/views/admin/resources/edit.html.erb
typus-3.1.6 app/views/admin/resources/edit.html.erb
typus-3.1.5 app/views/admin/resources/edit.html.erb
typus-3.1.4 app/views/admin/resources/edit.html.erb
typus-3.1.3 app/views/admin/resources/edit.html.erb