moiristo / deep_cloneable

This gem gives every ActiveRecord::Base object the possibility to do a deep clone that includes user specified associations.
MIT License
786 stars 88 forks source link

ActionText and attachments #112

Closed vitobotta closed 5 years ago

vitobotta commented 5 years ago

Hi! I am looking to implement some sort of versioning of a complex structure so this gem looks perfect for that. I have a page model which has many blocks (STI models), and one of these blocks types has ActionText rich text with attachments. What is the best/easiest way to use this gem in this case? I would prefer the shallow copy method so to keep only one copy of each file.

Thanks!

moiristo commented 5 years ago

Hi! Unfortunately I haven't used ActionText yet, so I don't know. I did find that ActionText creates an association, so maybe you could just include that?

vitobotta commented 5 years ago

Hi @moiristo ! Sounds like it would work. I'm doing something else now but I will try asap. Thanks!