Snapshot of main at 9f39a6e1e (2026-11-02)

This commit is contained in:
Ronald Huynen committed 2026-11-02 10:41:47 +01:00
commit 6ccf1792d7
2580 files changed
+1040202

No files matched your search

+21
View File
@@ -0,0 +1,21 @@
<?php
namespace App\Traits;
use Illuminate\Support\Carbon;
use Illuminate\Support\Facades\Http;
trait DateTimeTrait
{
/**
* Return “yes” / “planned” / “no” based on $field’s timestamp.
*/
protected function dateStatus(?string $ts): string
{
if (is_null($ts)) {
return __('no');
}
$dt = \Illuminate\Support\Carbon::parse($ts);
return $dt->isFuture() ? __('planned') : __('yes');
}
}