Sha256: 3c717c718d43ccc83269ac7dad87da70b4efa64d24bbe419cd0b66aba3a95a27

Contents?: true

Size: 1.02 KB

Versions: 7

Compression:

Stored size: 1.02 KB

Contents

# ПОДкатегории строительных материалов
ActiveAdmin.register C80Estate::Atype, :as => 'Atype' do

  menu :label => "Типы", :parent => "Настройки"

  permit_params :title,
                :slug,
                :prop_name_ids => []

  config.sort_order = 'id_asc'

  # controller do
  #   cache_sweeper :strsubcat_sweeper, :only => [:update,:create,:destroy]
  # end

  before_filter :skip_sidebar!, :only => :index

  # filter :title

  # controller do
  #   cache_sweeper :suit_sweeper, :only => [:update,:create,:destroy]
  # end

  index do
    selectable_column
    id_column
    column :title
    actions
  end

  form(:html => {:multipart => true}) do |f|

    f.inputs "Свойства" do
      f.input :title
    end

    f.inputs "Характеристики, которыми описываются объекты недвижимости и площади этого типа", :class => 'collapsed' do
      f.input :prop_names, :as => :check_boxes
    end

    f.actions
  end

end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
c80_estate-0.1.0.7 app/admin/c80_estate/atypes.rb
c80_estate-0.1.0.6 app/admin/c80_estate/atypes.rb
c80_estate-0.1.0.5 app/admin/c80_estate/atypes.rb
c80_estate-0.1.0.4 app/admin/c80_estate/atypes.rb
c80_estate-0.1.0.3 app/admin/c80_estate/atypes.rb
c80_estate-0.1.0.2 app/admin/c80_estate/atypes.rb
c80_estate-0.1.0.1 app/admin/c80_estate/atypes.rb