feat: treat all uploads of type 'document' as global

This commit is contained in:
Björn Fromme
2024-01-31 18:05:56 +01:00
parent 5ad7bfe769
commit 4be039e482
12 changed files with 15 additions and 130 deletions
@@ -25,10 +25,6 @@
{{ form_widget(form.showAvailableDispositions) }}
</div>
</div>
{# <div class="grid lg:grid-cols-2 gap-x-8 gap-y-4">#}
{# {{ form_row(form.dateFrom) }}#}
{# {{ form_row(form.dateTo) }}#}
{# </div>#}
<div class="grid lg:grid-cols-2 gap-x-8 gap-y-4">
{{ form_row(form.jobProfile) }}
{{ form_row(form.contact) }}
@@ -44,25 +40,7 @@
<div class="grid lg:grid-cols-2 gap-x-8 gap-y-4">
{{ form_row(form.benefits) }}
{{ form_row(form.fees) }}
</div>
<div class="grid lg:grid-cols-2 gap-x-8 gap-y-4">
{{ form_row(form.remarks) }}
<div {{ stimulus_controller('form-collection', { 'prototype': _self.collectionRow(form.documents.vars.prototype)|json_encode }) }}>
<h4 class="font-bold pb-2">
Dokumente
</h4>
<div {{ stimulus_target('form-collection', 'fields')}} class="flex flex-col space-y-4 mb-4">
{% do form.documents.setRendered %}
{%- for document in form.documents -%}{{- _self.collectionRow(document) -}}{%- endfor -%}
</div>
<div class="flex justify-end">
<button type="button"
{{ stimulus_action('form-collection', 'addItem') }}
title="Dokument hinzufügen">
{{ icon('plus', 'w-4 h-4 pointer-events-none') }}
</button>
</div>
</div>
</div>
</div>
<div class="flex items-center space-x-2">