Initial commit

This commit is contained in:
2025-07-15 23:39:10 +02:00
parent 1d3986a901
commit fb14214612
181 changed files with 31070 additions and 50 deletions

View File

@ -0,0 +1,4 @@
<form method="post" action="{{ path('bo_map_delete', {'id': map.id}) }}" onsubmit="return confirm('Are you sure you want to delete this item?');">
<input type="hidden" name="_token" value="{{ csrf_token('delete' ~ map.id) }}">
<button class="btn">Delete</button>
</form>

View File

@ -0,0 +1,11 @@
{% extends 'base.html.twig' %}
{% block body %}
<h1>Edit Map</h1>
{{ include('map/_form.html.twig', {'button_label': 'Update'}) }}
<a href="{{ path('bo_map_index') }}">back to list</a>
{{ include('map/_delete_form.html.twig') }}
{% endblock %}

View File

@ -0,0 +1,37 @@
{% extends 'base.html.twig' %}
{% block body %}
<h1>Map index</h1>
<table class="table">
<thead>
<tr>
<th>Id</th>
<th>File</th>
<th>ModifiedAt</th>
<th>Version</th>
<th>actions</th>
</tr>
</thead>
<tbody>
{% for map in maps %}
<tr>
<td>{{ map.id }}</td>
<td>{{ map.file }}</td>
<td>{{ map.modifiedAt ? map.modifiedAt|date('Y-m-d H:i:s') : '' }}</td>
<td>{{ map.version }}</td>
<td>
{#<a href="{{ path('map_show', {'id': map.id}) }}">show</a>#}
<a href="{{ path('bo_map_edit', {'id': map.id}) }}">edit</a>
</td>
</tr>
{% else %}
<tr>
<td colspan="5">no records found</td>
</tr>
{% endfor %}
</tbody>
</table>
<a href="{{ path('bo_map_new') }}">Create new</a>
{% endblock %}

View File

@ -0,0 +1,9 @@
{% extends 'base.html.twig' %}
{% block body %}
<h1>Create new Map</h1>
{{ include('map/_form.html.twig') }}
<a href="{{ path('bo_map_index') }}">back to list</a>
{% endblock %}

View File

@ -0,0 +1,32 @@
{% extends 'base.html.twig' %}
{% block body %}
<h1>Map</h1>
<table class="table">
<tbody>
<tr>
<th>Id</th>
<td>{{ map.id }}</td>
</tr>
<tr>
<th>File</th>
<td>{{ map.file }}</td>
</tr>
<tr>
<th>ModifiedAt</th>
<td>{{ map.modifiedAt ? map.modifiedAt|date('Y-m-d H:i:s') : '' }}</td>
</tr>
<tr>
<th>Version</th>
<td>{{ map.version }}</td>
</tr>
</tbody>
</table>
<a href="{{ path('bo_map_index') }}">back to list</a>
<a href="{{ path('bo_map_edit', {'id': map.id}) }}">edit</a>
{{ include('map/_delete_form.html.twig') }}
{% endblock %}

View File

@ -0,0 +1,10 @@
{{ form_start(form, {'name': "", 'attr': {'class': 'sp_grid__map-form sp_form__xhr sp_form__onchange'}}) }}
{{ form_widget(form.file, {'id': 'map_file' ~ idHash, 'attr': {'data-file-preview-target': 'map' ~ idHash}}) }}
{% if route|end_with('_new') %}
{{ form_widget(form.version, {'id': 'map_version' ~ idHash}) }}
{% endif %}
{{ form_widget(form._token, {'id': 'map__token' ~ idHash}) }}
{#<button class="btn">Save</button>#}
{{ form_end(form) }}