📅  最后修改于: 2022-03-11 14:53:59.980000             🧑  作者: Mango
try {
Date::excelToDateTimeObject(trim($row[5]))->format('Y-m-d');
} catch (\Exception $exception) {
throw ValidationException::withMessages([
'file' => "contains incorrect date format, should be in Y-m-d format"]
]);
}