jeudi 16 juin 2016

Laravel: how to set date format on model atribute casting?

I have in model:

protected $casts = [
    'date' => 'date',
];

Does laravel have some ability to set cast format, something like :

protected $casts = [
    'date' => 'date_format:d/m/yyyy',
];

?



via Chebli Mohamed

Aucun commentaire:

Enregistrer un commentaire