ruby-on-railsrubyrails-admin

How can I set a text template on edit for Rails-Admin?



It's just a question.
Is it possible to set a text template on edit for Rails-Admin?

Whenever inputting some data, it takes a long time.
So, I think if I can call like a mail template, it would takes a short.

I searched that kind of the function for Rails-Admin but I couldn't find it..
Any ideas?

Solution

  • Rails admin does not have anything special that can help you with this. The edit view, the closest thing that could help you, is auto-generated from the model fields and associations. And unless you want to add a model for each template you probably should steer clear of this approach.

    What you need is to build a custom action. You'd have to practically build everything like a regular controller. Check out the actions page of the rails admin wiki for instructions on how to do this.

    Good luck