Generators
# general
w
Hey folks! Got a question ... I'm integrating the
pay
gem for my client and they want the details in the admin dashboard as well. I've created a
Avo::Resources::Pay::Customer
resource and defined
self.model_class = Pay::Customer
... this still expects a
Avo::CustomersController
though. Is there any way to manually define which controller a resource should use?
l
Hello! Namespaced resources are on our roadmap. For this use case you may want to use the generator:
rails g avo:resource pay_customer --model_class="Pay::Customer"
This will generate the resource and the controller for it
Also will assign the
self.model_class = ::Pay::Customer
model to the fresh generated resource
I've should started with this: Welcome! Nice to see you here! 😄 We have this #740900436722188401 channel if you feel like sharing
w
Thanks for the tip 🙂 Yup I'll add an introduction soon!