🎉 first commit

This commit is contained in:
2026-07-18 00:01:27 +02:00
commit 78346ffece
63 changed files with 11664 additions and 0 deletions
+24
View File
@@ -0,0 +1,24 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>{% block title %}Welcome!{% endblock %}</title>
<link rel="icon" href="data:image/svg+xml,<svg xmlns=%22http://www.w3.org/2000/svg%22 viewBox=%220 0 128 128%22><text y=%221.2em%22 font-size=%2296%22>⚫️</text><text y=%221.3em%22 x=%220.2em%22 font-size=%2276%22 fill=%22%23fff%22>sf</text></svg>">
{% block stylesheets %}
{% endblock %}
{% block javascripts %}
{% block importmap %}{{ importmap('app') }}{% endblock %}
{% endblock %}
{% set frankenphp_hot_reload = app.request.server.get('FRANKENPHP_HOT_RELOAD') %}
{% if frankenphp_hot_reload %}
<meta name="frankenphp-hot-reload:url" content="{{ frankenphp_hot_reload }}">
<script src="https://cdn.jsdelivr.net/npm/idiomorph"></script>
<script src="https://cdn.jsdelivr.net/npm/frankenphp-hot-reload/+esm" type="module"></script>
{% endif %}
</head>
<body>
{% block body %}{% endblock %}
</body>
</html>
+4
View File
@@ -0,0 +1,4 @@
<form method="post" action="{{ path('app_todo_delete', {'id': todo.id}) }}" onsubmit="return confirm('Are you sure you want to delete this item?');">
<input type="hidden" name="_token" value="{{ csrf_token('delete' ~ todo.id) }}">
<button class="btn">Delete</button>
</form>
+4
View File
@@ -0,0 +1,4 @@
{{ form_start(form) }}
{{ form_widget(form) }}
<button class="btn">{{ button_label|default('Save') }}</button>
{{ form_end(form) }}
+13
View File
@@ -0,0 +1,13 @@
{% extends 'base.html.twig' %}
{% block title %}Edit Todo{% endblock %}
{% block body %}
<h1>Edit Todo</h1>
{{ include('todo/_form.html.twig', {'button_label': 'Update'}) }}
<a href="{{ path('app_todo_index') }}">back to list</a>
{{ include('todo/_delete_form.html.twig') }}
{% endblock %}
+39
View File
@@ -0,0 +1,39 @@
{% extends 'base.html.twig' %}
{% block title %}Todo index{% endblock %}
{% block body %}
<h1>Todo index</h1>
<table class="table">
<thead>
<tr>
<th>Id</th>
<th>Title</th>
<th>Completed</th>
<th>CreatedAt</th>
<th>actions</th>
</tr>
</thead>
<tbody>
{% for todo in todos %}
<tr>
<td>{{ todo.id }}</td>
<td>{{ todo.title }}</td>
<td>{{ todo.completed ? 'Yes' : 'No' }}</td>
<td>{{ todo.createdAt ? todo.createdAt|date('Y-m-d H:i:s') : '' }}</td>
<td>
<a href="{{ path('app_todo_show', {'id': todo.id}) }}">show</a>
<a href="{{ path('app_todo_edit', {'id': todo.id}) }}">edit</a>
</td>
</tr>
{% else %}
<tr>
<td colspan="5">no records found</td>
</tr>
{% endfor %}
</tbody>
</table>
<a href="{{ path('app_todo_new') }}">Create new</a>
{% endblock %}
+11
View File
@@ -0,0 +1,11 @@
{% extends 'base.html.twig' %}
{% block title %}New Todo{% endblock %}
{% block body %}
<h1>Create new Todo</h1>
{{ include('todo/_form.html.twig') }}
<a href="{{ path('app_todo_index') }}">back to list</a>
{% endblock %}
+34
View File
@@ -0,0 +1,34 @@
{% extends 'base.html.twig' %}
{% block title %}Todo{% endblock %}
{% block body %}
<h1>Todo</h1>
<table class="table">
<tbody>
<tr>
<th>Id</th>
<td>{{ todo.id }}</td>
</tr>
<tr>
<th>Title</th>
<td>{{ todo.title }}</td>
</tr>
<tr>
<th>Completed</th>
<td>{{ todo.completed ? 'Yes' : 'No' }}</td>
</tr>
<tr>
<th>CreatedAt</th>
<td>{{ todo.createdAt ? todo.createdAt|date('Y-m-d H:i:s') : '' }}</td>
</tr>
</tbody>
</table>
<a href="{{ path('app_todo_index') }}">back to list</a>
<a href="{{ path('app_todo_edit', {'id': todo.id}) }}">edit</a>
{{ include('todo/_delete_form.html.twig') }}
{% endblock %}