Before save copy body in rich_body

This commit is contained in:
Mathieu Magnin 2019-04-10 15:21:08 +02:00 committed by Paul Chavard
parent d13b7f953f
commit 10d3ba10f2
2 changed files with 11 additions and 0 deletions

View file

@ -11,8 +11,13 @@ module MailTemplateConcern
replace_tags(body, dossier)
end
def update_rich_body
self.rich_body = self.body
end
included do
has_rich_text :rich_body
before_save :update_rich_body
end
module ClassMethods