Sha256: 457a3a1eda948e878d761bb57cc358b9672695c627b9ab0c3859b4c19f4ac536
Contents?: true
Size: 926 Bytes
Versions: 8
Compression:
Stored size: 926 Bytes
Contents
- read_only = !%w[new create edit update].include?(action_name) = simple_form_for(@resource, builder: CustomFormBuilder) do |f| .card.card-primary .card-header %h3.card-title= @resource.to_s.blank? ? @resource.model_name.human : @resource .card-tools = resource_form_actions(@resource, for_action: action_name.to_sym) .card-body =f.error_notification =f.error_notification message: f.object.errors[:base].to_sentence if f.object.errors[:base].present? = render_optional_partial 'form_inside_before', locals: {f: f} = render Olivander::Components::ResourceFormComponent.new(@resource, f) = render_optional_partial 'form_inside_after', locals: {f: f} .card-footer.text-right = link_to 'Cancel', @cancel_path || @_effective_resource.action_path(:index), class: 'btn btn-secondary' - unless read_only = f.button :submit, class: 'btn btn-primary'
Version data entries
8 entries across 8 versions & 1 rubygems