Is it possible to add behaviors (eg. actAs Timestampable) in a doctrine migration to avoid defining the created_at and updated_at columns ?
Thank’s in advance !
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
I think there is no way to add behaviors in the migration code.
BUT! if you are using doctrine 1.1 (it’s easy to migrate from 1.0) you can instead modify your schema, add the behavior, and let doctrine generate the migration code as explained here:
http://www.doctrine-project.org/blog/new-to-migrations-in-1-1