Here's the code for the Organisation class class Organisation < Sequel::Model
before_validation do if self.new? self.uuid = UUID.random_create.to_s end end before_create do creation_time = Time.now self.created_at = creation_time self.updated_at = creation_time self.active = true end before_update do update_time = Time.now self.updated_at = update_time end end --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "sequel-talk" group. To post to this group, send email to sequel-talk@googlegroups.com 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 -~----------~----~----~----~------~----~------~--~---