Start of work on templates - identify templates that apply to existing entries

This commit is contained in:
2025-06-09 14:26:01 +10:00
parent 8602c2b17f
commit 820f398c2c
11 changed files with 305 additions and 41 deletions

View File

@@ -0,0 +1,17 @@
<!-- $template=Template -->
<form id="template-edit" method="POST" class="needs-validation" action="{{ url('entry/update/pending') }}" novalidate readonly>
@csrf
<input type="hidden" name="dn" value="">
<div class="card-body">
<div class="tab-content">
@php($up=(session()->pull('updated') ?: collect()))
@php($attributes=$o->template($template)?->attributes)
@foreach($o->getVisibleAttributes()->filter(fn($item)=>in_array($item,$attributes)) as $ao)
<x-attribute-type :o="$ao" :edit="TRUE" :new="FALSE" :updated="$up->contains($ao->name_lc)"/>
@endforeach
</div>
</div>
</form>