Sha256: c2c3df2903f61d51c87cdf1f57401e7b4a5864ffe34a11db9a7a0c686bbac43c

Contents?: true

Size: 748 Bytes

Versions: 3

Compression:

Stored size: 748 Bytes

Contents

= effective_form_with(model: [:admin, stamp], engine: true) do |f|
  - if inline_datatable?
    = f.hidden_field :owner_id
    = f.hidden_field :owner_type

  - else
    - ajax_url = (@select2_ajax_path || effective_resources.users_admin_select2_ajax_index_path) unless Rails.env.test?
    - f.object.owner_type ||= current_user.class.name

    = f.select :owner_id, current_user.class.all, label: 'User', ajax_url: ajax_url,
      'data-load-ajax-url': effective_products.new_admin_stamp_path,
      'data-load-ajax-div': '#effective-stamps-ajax'

  #effective-stamps-ajax
    = render 'effective/stamps/fields', f: f, stamp: f.object

    = f.submit do
      = f.save 'Save'

      - if f.object.new_record?
        = f.save 'Save and Mark Paid'

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
effective_products-0.3.0 app/views/admin/stamps/_form.html.haml
effective_products-0.2.1 app/views/admin/stamps/_form.html.haml
effective_products-0.2.0 app/views/admin/stamps/_form.html.haml