Class: Step5RailsResourceRoutes
- Inherits:
-
KDomain::DomainModel::Step
- Object
- KDomain::DomainModel::Step
- Step5RailsResourceRoutes
- Defined in:
- lib/k_domain/domain_model/transform_steps/step5_rails_resource_routes.rb
Overview
Locate rails model files
Instance Attribute Summary
Attributes inherited from KDomain::DomainModel::Step
Instance Method Summary collapse
Methods inherited from KDomain::DomainModel::Step
#camel, #database, #database=, #database_foreign_keys, #database_tables, #domain, #domain_models, #find_foreign_table, #find_rails_structure_models, #find_table_for_model, #guard, #initialize, #investigate, #issues, #rails_resource, #rails_resource_controllers, #rails_resource_models, #rails_resource_models=, #rails_resource_routes, #rails_resource_routes=, #rails_structure, #rails_structure_controllers, #rails_structure_controllers=, #rails_structure_models, #rails_structure_models=, run, #table_name_exist?, #warning, #write
Constructor Details
This class inherits a constructor from KDomain::DomainModel::Step
Instance Method Details
#call ⇒ Object
5 6 7 8 9 10 11 12 |
# File 'lib/k_domain/domain_model/transform_steps/step5_rails_resource_routes.rb', line 5 def call return warning('Routes .json file not supplied') if opts[:route_path].nil? return warning('Routes .json file not found') unless File.exist?(opts[:route_path]) warning('Controller path not supplied. Routes will be loaded but not paired with a controller') if opts[:controller_path].nil? self.rails_resource_routes = load_routes(opts[:route_path], opts[:controller_path]) end |