setting $dateFormat property on your model. This property determines how date attributes are stored in the database. Format is the same as in php's date functions
helmerdavila, could you tell me, why i have error if my date is NULL?
If i have some value, it works, but if not, i have this error:
"Call to a member function format() on a non-object"