Fix Event & EventType resource issues and apply formatting
- Fix EventType deletion error handling (constraint violations) - Fix Event update error (package_id column missing) - Fix Event Type dropdown options (JSON display issue) - Fix EventPackagesRelationManager query error - Add missing translations for deletion errors - Apply Pint formatting
This commit is contained in:
@@ -9,7 +9,7 @@ return new class extends Migration
|
||||
public function up(): void
|
||||
{
|
||||
// Event Types
|
||||
if (!Schema::hasTable('event_types')) {
|
||||
if (! Schema::hasTable('event_types')) {
|
||||
Schema::create('event_types', function (Blueprint $table) {
|
||||
$table->id();
|
||||
$table->json('name');
|
||||
@@ -21,7 +21,7 @@ return new class extends Migration
|
||||
}
|
||||
|
||||
// Emotions
|
||||
if (!Schema::hasTable('emotions')) {
|
||||
if (! Schema::hasTable('emotions')) {
|
||||
Schema::create('emotions', function (Blueprint $table) {
|
||||
$table->id();
|
||||
$table->json('name');
|
||||
@@ -35,7 +35,7 @@ return new class extends Migration
|
||||
}
|
||||
|
||||
// Pivot table for emotions and event types
|
||||
if (!Schema::hasTable('emotion_event_type')) {
|
||||
if (! Schema::hasTable('emotion_event_type')) {
|
||||
Schema::create('emotion_event_type', function (Blueprint $table) {
|
||||
$table->unsignedBigInteger('emotion_id');
|
||||
$table->unsignedBigInteger('event_type_id');
|
||||
@@ -54,4 +54,4 @@ return new class extends Migration
|
||||
Schema::dropIfExists('event_types');
|
||||
}
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user