Model data templates

hi,

i’m looking for suggestions how to setup and manage relatively small
default data sets to be used as templates.

lets say a user can have a default set of objects involving several
models, and there might be several default sets to pick from
(template objects).

Would you suggest I create the ‘templates’ in the db as specially
named records, and copy them to the user, or create a method that
just makes a series of create calls, or use an external file like
yaml, or use xml, etc… ??

One approach I’m thinking of creating the sets of objects in the db
via a data migration via yml files, and then cloning them from the db
when the user picks one, but that means the templates would be spread
across multiple yml files, one for each model. I’d prefer to keep
them together.

linoj

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs