WIP: Implement feedback functionality

This commit is contained in:
Björn Fromme
2023-11-03 09:20:48 +01:00
parent d024e11f8f
commit d016ee043a
12 changed files with 123 additions and 73 deletions
@@ -13,13 +13,13 @@
{{ form_start(form) }}
<div class="flex flex-col space-y-4 pb-8">
{{ form_row(form.name) }}
<div {{ stimulus_controller('form-collection', { 'prototype': _self.collectionRow(form.items.vars.prototype)|json_encode }) }}>
<div {{ stimulus_controller('form-collection', { 'prototype': _self.collectionRow(form.ratings.vars.prototype)|json_encode }) }}>
<h4 class="font-bold pb-2">
Bewertungen
</h4>
<div {{ stimulus_target('form-collection', 'fields')}} class="flex flex-col space-y-4 mb-4">
{% do form.items.setRendered %}
{%- for item in form.items -%}{{- _self.collectionRow(item) -}}{%- endfor -%}
{% do form.ratings.setRendered %}
{%- for item in form.ratings -%}{{- _self.collectionRow(item) -}}{%- endfor -%}
</div>
<div class="flex justify-end">
<button type="button"
@@ -28,7 +28,7 @@
{{ icon('plus', 'w-4 h-4 pointer-events-none') }}
</button>
</div>
{{ form_errors(form.items) }}
{{ form_errors(form.ratings) }}
</div>
</div>
<div class="flex items-center space-x-2">