开发者

When are 'created_at' and 'updated_at' set?

I'm trying to use the created_at and updated_at in my before_create but they do not appear to be se开发者_开发问答t. Any idea when they are set? Thanks!


created_at attribute is set automatically after object is created, updated_at -- updates after every updating. So, I guess, you cant use it before creating an object

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜