Class: BlockSelectorInput
- Inherits:
-
SimpleForm::Inputs::CollectionSelectInput
- Object
- SimpleForm::Inputs::CollectionSelectInput
- BlockSelectorInput
- Defined in:
- app/inputs/block_selector_input.rb
Instance Method Summary collapse
Instance Method Details
#collection ⇒ Object
13 14 15 |
# File 'app/inputs/block_selector_input.rb', line 13 def collection [] end |
#input(wrapper_options) ⇒ Object
2 3 4 5 6 7 8 9 10 11 |
# File 'app/inputs/block_selector_input.rb', line 2 def input() [:hint] ||= 'Select a block from blocks on this page. You\'ll need to save the page after adding new blocks for them to appear in this list.' if object.try(:anchor).present? [:data] ||= {} [:data]['selected'] = object.anchor end super end |