mirror of
https://github.com/snipe/snipe-it.git
synced 2024-12-25 05:34:06 -08:00
Fixes date sanity check in checkout
This commit is contained in:
parent
30c6657fc1
commit
97e218541b
|
@ -186,7 +186,7 @@ class Asset extends Depreciable
|
|||
$logaction->checkedout_to = $this->assigned_to;
|
||||
$logaction->asset_type = 'hardware';
|
||||
$logaction->note = $note;
|
||||
if ($checkout_at) {
|
||||
if ($checkout_at!='') {
|
||||
$logaction->created_at = \Carbon\Carbon::createFromFormat('Y-m-d H:i:s', date('Y-m-d H:i:s', strtotime($checkout_at)));
|
||||
} else {
|
||||
$logaction->created_at = \Carbon\Carbon::now();
|
||||
|
|
Loading…
Reference in a new issue