Class: ActiveScaffold::Config::Core::UserSettings
Instance Attribute Summary collapse
Instance Method Summary
collapse
#configure
#[], #[]=, #core, #initialize, #key?, #proxy_to_conf?, session_attr, #user, user_attr
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(name, *args) ⇒ Object
316
317
318
319
|
# File 'lib/active_scaffold/config/core.rb', line 316
def method_missing(name, *args)
value = @conf.actions.include?(name) ? @conf.send(name) : super
value.is_a?(Base) ? action_user_settings(value) : value
end
|
Instance Attribute Details
#label(options = {}) ⇒ Object
312
313
314
|
# File 'lib/active_scaffold/config/core.rb', line 312
def label(options = {})
@label ? as_(@label, options) : @conf.label(options)
end
|
Instance Method Details
#action_links ⇒ Object
336
337
338
|
# File 'lib/active_scaffold/config/core.rb', line 336
def action_links
@conf.action_links
end
|
#action_user_settings(action_config) ⇒ Object
325
326
327
328
329
330
|
# File 'lib/active_scaffold/config/core.rb', line 325
def action_user_settings(action_config)
if action_config.user.nil? && action_config.respond_to?(:new_user_settings)
action_config.new_user_settings @storage, @params
end
action_config.user || action_config
end
|
344
345
346
|
# File 'lib/active_scaffold/config/core.rb', line 344
def actions
@conf.actions end
|
332
333
334
|
# File 'lib/active_scaffold/config/core.rb', line 332
def columns
@columns ||= UserColumns.new(@conf.columns)
end
|
340
341
342
|
# File 'lib/active_scaffold/config/core.rb', line 340
def model
@conf.model end
|
#respond_to_missing?(name, include_all = false) ⇒ Boolean
321
322
323
|
# File 'lib/active_scaffold/config/core.rb', line 321
def respond_to_missing?(name, include_all = false)
super end
|