Sequel Model plugin to implicitly set created_at and updated_at
License
cohuman/sequel_timestamped
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
If your model is :timestamped, it will automatically set the :created_at and :updated_at columns if they exist With a migration like: class MessageMigration < Sequel::Migration def up create_table :messages do primary_key :id integer :user_id string :name boolean :direct datetime :created_at datetime :updated_at end end def down execute "DROP TABLE messages" end end a class with class Message < Sequel::Model is :timestamped belongs_to :user end will be autotimestamped
About
Sequel Model plugin to implicitly set created_at and updated_at
Resources
License
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published