add order
All checks were successful
/ ls (pull_request) Successful in 27s
/ ls (push) Successful in 27s

This commit is contained in:
lubiana 2024-06-14 17:41:00 +02:00
parent 7663f684a4
commit 1dc5306967
No known key found for this signature in database
37 changed files with 1060 additions and 113 deletions

View file

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

View file

@ -0,0 +1,4 @@
{{ form_start(form) }}
{{ form_widget(form) }}
<button class="btn">{{ button_label|default('Save') }}</button>
{{ form_end(form) }}

View file

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

View file

@ -0,0 +1,37 @@
{% extends 'base.html.twig' %}
{% block title %}OrderItem index{% endblock %}
{% block body %}
<h1>OrderItem index</h1>
<table class="table">
<thead>
<tr>
<th>Id</th>
<th>Name</th>
<th>Extras</th>
<th>actions</th>
</tr>
</thead>
<tbody>
{% for order_item in order_items %}
<tr>
<td>{{ order_item.id }}</td>
<td>{{ order_item.name }}</td>
<td>{{ order_item.extras }}</td>
<td>
<a href="{{ path('app_order_item_show', {'id': order_item.id}) }}">show</a>
<a href="{{ path('app_order_item_edit', {'id': order_item.id}) }}">edit</a>
</td>
</tr>
{% else %}
<tr>
<td colspan="4">no records found</td>
</tr>
{% endfor %}
</tbody>
</table>
<a href="{{ path('app_order_item_new') }}">Create new</a>
{% endblock %}

View file

@ -0,0 +1,11 @@
{% extends 'base.html.twig' %}
{% block title %}New OrderItem{% endblock %}
{% block body %}
<h1>Create new OrderItem</h1>
{{ include('order_item/_form.html.twig') }}
<a href="{{ path('app_order_item_index') }}">back to list</a>
{% endblock %}

View file

@ -0,0 +1,30 @@
{% extends 'base.html.twig' %}
{% block title %}OrderItem{% endblock %}
{% block body %}
<h1>OrderItem</h1>
<table class="table">
<tbody>
<tr>
<th>Id</th>
<td>{{ order_item.id }}</td>
</tr>
<tr>
<th>Name</th>
<td>{{ order_item.name }}</td>
</tr>
<tr>
<th>Extras</th>
<td>{{ order_item.extras }}</td>
</tr>
</tbody>
</table>
<a href="{{ path('app_order_item_index') }}">back to list</a>
<a href="{{ path('app_order_item_edit', {'id': order_item.id}) }}">edit</a>
{{ include('order_item/_delete_form.html.twig') }}
{% endblock %}