Answers for "laravel migration datetime now"

PHP
1

current time in laravel migration

$table->timestamp('column_name')->useCurrent();
Posted by: Guest on November-27-2020
0

datetime-local laravel migration data type

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

public function getDateEndAttribute($value)
{
    return Carbon::parse($value)->format('Y-m-d\TH:i');
}
Posted by: Guest on December-11-2020

Code answers related to "laravel migration datetime now"

Browse Popular Code Answers by Language