Class: ActiveRecord::Generators::NiceACLGenerator
- Inherits:
-
Base
- Object
- Base
- ActiveRecord::Generators::NiceACLGenerator
- Defined in:
- lib/generators/active_record/nice_acl_generator.rb
Instance Method Summary collapse
Instance Method Details
#generate_model ⇒ Object
14 15 16 |
# File 'lib/generators/active_record/nice_acl_generator.rb', line 14 def generate_model invoke 'active_record:model', [name], migration: false end |
#inject_role_class ⇒ Object
18 19 20 21 |
# File 'lib/generators/active_record/nice_acl_generator.rb', line 18 def inject_role_class require "#{ENGINE_ROOT}/app/models/#{user_cname.downcase}.rb" inject_into_class(model_path, class_name, model_content) end |