2011-11-09 01:42:19 -05:00
|
|
|
module Rails
|
|
|
|
module ConsoleMethods
|
2013-07-18 10:18:04 -04:00
|
|
|
# Gets the helper methods available to the controller.
|
|
|
|
#
|
2013-07-18 11:15:09 -04:00
|
|
|
# This method assumes an +ApplicationController+ exists, and it extends +ActionController::Base+
|
2011-11-03 15:50:53 -04:00
|
|
|
def helper
|
|
|
|
@helper ||= ApplicationController.helpers
|
|
|
|
end
|
2006-03-23 16:56:38 -05:00
|
|
|
|
2013-07-18 10:18:04 -04:00
|
|
|
# Gets a new instance of a controller object.
|
|
|
|
#
|
2013-07-18 11:15:09 -04:00
|
|
|
# This method assumes an +ApplicationController+ exists, and it extends +ActionController::Base+
|
2011-11-03 15:50:53 -04:00
|
|
|
def controller
|
|
|
|
@controller ||= ApplicationController.new
|
|
|
|
end
|
|
|
|
end
|
2010-03-07 09:24:30 -05:00
|
|
|
end
|