After 2 years, i'm now with Laravel 12, and i got the same problem.
In my first model,
protected function casts(): array
{
return [
'depot' => 'datetime',
];
}
it's ok, i have a UTC format.
In a second model :
protected function casts(): array
{
return [
'email_verified_at' => 'datetime',
'validation_parcellaire' => 'datetime',
];
}
For the 2 fields i have "yyyy-mm-dd hh:mm:ss", why it doesn't cast on the second model ?
Regards