Hi, I wan't to do something with a model after it has been saved, i.e.
associate it with a list of tags after the model is saved but by then
I loose my instance variables, this is the only non obvious for me
behavior I found so far with sequel, I would not expect this to
happen.
class Cause < Sequel::Model
many_to_many :tags, :right_key => :tag_name
def tags= tags
@tag_names = tags.split(',').map(&:strip)
end
def after_update
@tag_names # => nil
super
end
end
So the way for associating on creation would be outside the model?
Thanks
--
You received this message because you are subscribed to the Google Groups
"sequel-talk" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/sequel-talk?hl=en.