Class: ProductLineGroupsPickerInput
- Inherits:
-
TomSelectInput
- Object
- SimpleForm::Inputs::CollectionSelectInput
- TomSelectInput
- ProductLineGroupsPickerInput
- Defined in:
- app/inputs/product_line_groups_picker_input.rb
Overview
SimpleForm input wrapper: product line groups picker.
Instance Method Summary collapse
Methods inherited from TomSelectInput
Instance Method Details
#collection ⇒ Object
4 5 6 7 8 9 |
# File 'app/inputs/product_line_groups_picker_input.rb', line 4 def collection ProductLine.where.not(lineage_expanded: nil).map do |pl| group = pl..split('>').first.strip [group, group] end.uniq.sort end |