Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PHP

datetime-local laravel migration data type

public function getDateStartAttribute($value)
{
    return Carbon::parse($value)->format('Y-m-dTH:i');
}

public function getDateEndAttribute($value)
{
    return Carbon::parse($value)->format('Y-m-dTH:i');
}
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #laravel #migration #data #type
ADD COMMENT
Topic
Name
4+2 =