Module: RademadeAdmin::ModelOptions
- Included in:
- ModelController
- Defined in:
- app/services/model_controller/model_options.rb
Instance Method Summary collapse
- #configuration ⇒ Object
- #item_name ⇒ Object
- #model_class ⇒ Object
- #model_info ⇒ Object
- #model_name ⇒ Object
-
#options(&options_block) ⇒ Object
Configure admin part of model Support options - model - name - parent_menu (todo extract to menu method) - menu_count - list - form - labels.
- #parent_menu_item ⇒ Object
Instance Method Details
#configuration ⇒ Object
39 40 41 |
# File 'app/services/model_controller/model_options.rb', line 39 def configuration @configuration ||= Model::Configuration.new(self) end |
#item_name ⇒ Object
23 24 25 |
# File 'app/services/model_controller/model_options.rb', line 23 def item_name configuration.item_name end |
#model_class ⇒ Object
31 32 33 |
# File 'app/services/model_controller/model_options.rb', line 31 def model_class configuration.model_class end |
#model_info ⇒ Object
35 36 37 |
# File 'app/services/model_controller/model_options.rb', line 35 def model_info @model_info ||= Model::Graph.instance.model_info(model_class) end |
#model_name ⇒ Object
19 20 21 |
# File 'app/services/model_controller/model_options.rb', line 19 def model_name configuration.model_name end |
#options(&options_block) ⇒ Object
Configure admin part of model Support options
- model
- name
- parent_menu (todo extract to menu method)
- menu_count
- list
- form
- labels
15 16 17 |
# File 'app/services/model_controller/model_options.rb', line 15 def (&) configuration.instance_eval & end |
#parent_menu_item ⇒ Object
27 28 29 |
# File 'app/services/model_controller/model_options.rb', line 27 def configuration. end |