Some code optimisation and de-duplication with components

This commit is contained in:
2025-01-15 23:29:53 +11:00
parent 8b922b2e8b
commit 6e06caa83b
15 changed files with 169 additions and 101 deletions

View File

@@ -1,36 +1,7 @@
@extends('home')
@section('page_title')
<table class="table table-borderless">
<tr>
<td class="{{ ($x=$o->getObject('jpegphoto')) ? 'border' : '' }}" rowspan="2">
{!! $x ? $x->render(FALSE,TRUE) : sprintf('<div class="page-title-icon f32"><i class="%s"></i></div>',$o->icon() ?? "fas fa-info") !!}
</td>
<td class="text-end align-text-top p-0 {{ $x ? 'ps-5' : 'pt-2' }}"><strong>{{ $dn }}</strong></td>
</tr>
<tr>
<td class="line-height-1" style="font-size: 55%;vertical-align: bottom;" colspan="2">
<table>
<tr>
<td class="p-1 m-1">Created</td>
<th class="p-1 m-1">
{{ ($x=$o->getObject('createtimestamp')) ? $x->render() : __('Unknown') }} [{{ ($x=$o->getObject('creatorsname')) ? $x->render() : __('Unknown') }}]
</th>
</tr>
<tr>
<td class="p-1 m-1">Modified</td>
<th class="p-1 m-1">
{{ ($x=$o->getObject('modifytimestamp')) ? $x->render() : __('Unknown') }} [{{ ($x=$o->getObject('modifiersname')) ? $x->render() : __('Unknown') }}]
</th>
</tr>
<tr>
<td class="p-1 m-1">UUID</td>
<th class="p-1 m-1">{{ $o->entryuuid[0] ?? '' }}</th>
</tr>
</table>
</td>
</tr>
</table>
@include('fragment.dn.header')
@endsection
@section('main-content')