Check in the model class if have
$timestamps = false
You need to remove it or set to true. and if in the migration in the schema builder you have used
$table->timestamps();
The model had no mention of $timestamps so I'd added this:
public $timestamps = true;
And the table was built with a migration containing
$table->timestamps();
Can you give us some code examples that aren't causing the timestamps to be updated?
Are they created initially when you use something like Model::create
?
THAT WAS IT!
I wasn't using Model::create I was doing...
DB::table('cars')->insert(... etc...
Thank you for your reply Jason. This really had me stumped.
In my case, I had to manually add public $timestamps = true;
to all Eloquent Models
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community