Sha256: b5095cb0b4e2c3f2431193336f3d21c2244f9f96764068cd152f7756656755cc

Contents?: true

Size: 1.08 KB

Versions: 22

Compression:

Stored size: 1.08 KB

Contents

<div>
  <% @resource.panels.each do |resource_panel| %>
    <%= form_with model: @resource.model, url: helpers.resources_path(@resource.model, via_relation_class: params[:via_relation_class], via_resource_id: params[:via_resource_id]), local: true, multipart: true do |form| %>
      <%= panel(title: resource_panel[:name]) do |component| %>
        <% component.with :tools do %>
          <div class="flex justify-end space-x-2">
            <%= a_link back_path do %>
              <%= svg 'arrow-left' %> <%= t('avo.cancel').capitalize %>
            <% end %>

            <%= a_button color: 'green', type: :submit do %>
              <%= svg 'save' %> <%= t('avo.save').capitalize %>
            <% end if @resource.authorization.authorize_action :create, raise_exception: false %>
          </div>
        <% end %>

        <% component.with :body do %>
          <% @resource.get_fields.each_with_index do |field, index| %>
            <%= edit_field field, index, @resource, form unless field.computed %>
          <% end %>
        <% end %>
      <% end %>
    <% end %>
  <% end %>
</div>

Version data entries

22 entries across 22 versions & 1 rubygems

Version Path
avo-1.1.0 app/components/avo/views/resource_new_component.html.erb
avo-1.1.0.pre.1 app/components/avo/views/resource_new_component.html.erb
avo-1.0.5 app/components/avo/views/resource_new_component.html.erb
avo-1.0.4 app/components/avo/views/resource_new_component.html.erb
avo-1.0.2 app/components/avo/views/resource_new_component.html.erb
avo-1.0.1 app/components/avo/views/resource_new_component.html.erb
avo-1.0.0 app/components/avo/views/resource_new_component.html.erb
avo-0.5.0.beta15 app/components/avo/views/resource_new_component.html.erb
avo-0.5.0.beta14 app/components/avo/views/resource_new_component.html.erb
avo-0.5.0.beta13 app/components/avo/views/resource_new_component.html.erb
avo-0.5.0.beta12 app/components/avo/views/resource_new_component.html.erb
avo-0.5.0.beta11 app/components/avo/views/resource_new_component.html.erb
avo-0.5.0.beta10 app/components/avo/views/resource_new_component.html.erb
avo-0.5.0.beta9 app/components/avo/views/resource_new_component.html.erb
avo-0.5.0.beta8 app/components/avo/views/resource_new_component.html.erb
avo-0.5.0.beta7 app/components/avo/views/resource_new_component.html.erb
avo-0.5.0.beta6 app/components/avo/views/resource_new_component.html.erb
avo-0.5.0.beta5 app/components/avo/views/resource_new_component.html.erb
avo-0.5.0.beta4 app/components/avo/views/resource_new_component.html.erb
avo-0.5.0.beta3 app/components/avo/views/resource_new_component.html.erb