Sha256: 373cbd379c1135d1eb3f05ce06c3c465b5b03e412fb9f81a79a20bf86b5f59eb

Contents?: true

Size: 1.06 KB

Versions: 3

Compression:

Stored size: 1.06 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' %>
    <script type="text/javascript">
      $(document).ready(function () {
        parent.Typus.resource_attribute = "#<%= params[:attribute] %>";
        parent.Typus.resource_id = '<%= @item.id %>';
        parent.Typus.resource_to_label = '<%= @item.to_label %>';
        <% if flash.keys.any? && !params[:_input] %>
          parent.Typus.parent_location_reload = true;
        <% end %>
      });
    </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

3 entries across 3 versions & 1 rubygems

Version Path
typus-3.1.2 app/views/admin/resources/edit.html.erb
typus-3.1.1 app/views/admin/resources/edit.html.erb
typus-3.1.0 app/views/admin/resources/edit.html.erb