moves timestamping of database models into parent model

Remake of #33