u
This commit is contained in:
@@ -96,6 +96,19 @@ export function formatDate(iso) {
|
||||
return d.toLocaleDateString('de-DE');
|
||||
}
|
||||
|
||||
export function formatDateTime(iso) {
|
||||
if (!iso) return '–';
|
||||
const d = new Date(iso);
|
||||
if (Number.isNaN(d.getTime())) return String(iso);
|
||||
return d.toLocaleString('de-DE', {
|
||||
day: '2-digit',
|
||||
month: '2-digit',
|
||||
year: 'numeric',
|
||||
hour: '2-digit',
|
||||
minute: '2-digit',
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Delivery documents have a server-allocated, read-only `number` plus an
|
||||
* optional user-entered `externalNumber`. Returns the display value for a
|
||||
|
||||
Reference in New Issue
Block a user