Sha256: 7c85fec96f0f3e09f29d3af4340b6b36cd31d2ad9614863b9637002533b704ca

Contents?: true

Size: 637 Bytes

Versions: 4

Compression:

Stored size: 637 Bytes

Contents

# frozen_string_literal: true

module Playbook
  module PbForm
    module FormBuilder
      module CollectionSelectField
        def collection_select(name, collection, value_method, text_method, options = {}, html_options = {}, props: {} )
          props[:label] = @template.label(@object_name, name) if props[:label] == true
          options[:skip_default_ids] = false unless options.has_key?(:skip_default_ids)
          input = super(name, collection, value_method, text_method, options, html_options)

          @template.pb_rails("select", props: props) do
            input
          end
        end
      end
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
playbook_ui-3.5.0 app/pb_kits/playbook/pb_form/form_builder/collection_select_field.rb
playbook_ui-3.4.0 app/pb_kits/playbook/pb_form/form_builder/collection_select_field.rb
playbook_ui-3.3.0 app/pb_kits/playbook/pb_form/form_builder/collection_select_field.rb
playbook_ui-3.2.0 app/pb_kits/playbook/pb_form/form_builder/collection_select_field.rb