mirror of
https://github.com/drapergem/draper
synced 2023-03-27 23:21:17 -04:00
WTF have I done to this branch
This commit is contained in:
parent
e4477b3993
commit
56d2b7a118
4 changed files with 2 additions and 2 deletions
|
@ -1,5 +1,5 @@
|
|||
module Draper
|
||||
class ModelGenerator < Rails::Generators::NamedBase
|
||||
class DecoratorGenerator < Rails::Generators::NamedBase
|
||||
source_root File.expand_path('../templates', __FILE__)
|
||||
|
||||
DECORATORS_ROOT = 'app/decorators/'
|
||||
|
@ -11,7 +11,7 @@ module Draper
|
|||
unless File.exists?(APPLICATION_DECORATOR_PATH)
|
||||
template APPLICATION_DECORATOR, APPLICATION_DECORATOR_PATH
|
||||
end
|
||||
template 'model.rb', "#{DECORATORS_ROOT}#{singular_name}_decorator.rb"
|
||||
template 'decorator.rb', "#{DECORATORS_ROOT}#{singular_name}_decorator.rb"
|
||||
end
|
||||
end
|
||||
end
|
Loading…
Add table
Reference in a new issue