Terminanmeldung mit Plätzen und Warteliste (0.31.0)
Some checks failed
CI / PHP 8.3 / mariadb:10.6 (pull_request) Successful in 5m10s
CI / PHP 8.4 / mariadb:10.6 (pull_request) Successful in 5m16s
CI / PHP 8.3 / mariadb:11.4 (pull_request) Successful in 5m42s
CI / PHP 8.4 / mariadb:11.4 (pull_request) Successful in 5m29s
CI / PHP 8.3 / mysql:8.0 (pull_request) Failing after 7m35s
CI / PHP 8.4 / mysql:8.0 (pull_request) Failing after 7m36s
CI / PHP 8.3 / mysql:8.4 (pull_request) Failing after 6m27s
CI / PHP 8.4 / mysql:8.4 (pull_request) Failing after 6m19s
CI / Bekannte Sicherheitslücken in Paketen (pull_request) Successful in 44s
CI / Build-Artefakte aktuell (pull_request) Successful in 1m10s

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
Friederich Loheide 2026-09-27 12:37:28 +00:00
parent 33a76458af
commit b293d2e05a
139 changed files with 1030 additions and 336 deletions

View file

@ -0,0 +1,43 @@
<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
/**
* Anmeldung zu Terminen: Plätze, Warteliste, Anmeldeschluss.
*/
return new class extends Migration
{
public function up(): void
{
Schema::table('events', function (Blueprint $table) {
$table->boolean('registration_enabled')->default(false)->after('is_published');
$table->unsignedInteger('capacity')->nullable()->after('registration_enabled');
$table->boolean('waitlist')->default(true)->after('capacity');
$table->timestamp('registration_deadline')->nullable()->after('waitlist');
$table->boolean('participants_public')->default(false)->after('registration_deadline');
});
Schema::create('event_registrations', function (Blueprint $table) {
$table->id();
$table->foreignId('event_id')->constrained('events')->cascadeOnDelete();
$table->foreignId('user_id')->constrained()->cascadeOnDelete();
$table->string('status', 20);
$table->string('note', 500)->nullable();
$table->timestamps();
$table->unique(['event_id', 'user_id']);
$table->index(['event_id', 'status', 'created_at']);
});
}
public function down(): void
{
Schema::dropIfExists('event_registrations');
Schema::table('events', function (Blueprint $table) {
$table->dropColumn(['registration_enabled', 'capacity', 'waitlist', 'registration_deadline', 'participants_public']);
});
}
};