fix: use finished_at for the end time instead of created_at

This commit is contained in:
peaklabs-dev
2025-01-16 15:12:57 +01:00
parent 48b10de4f3
commit 30f36f96db
11 changed files with 66 additions and 31 deletions

View File

@@ -19,6 +19,7 @@ return new class extends Migration
$table->json('cleanup_log')->nullable();
$table->foreignId('server_id');
$table->timestamps();
$table->timestamp('finished_at')->nullable();
});
}

View File

@@ -1,22 +0,0 @@
<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
return new class extends Migration
{
public function up()
{
Schema::table('application_deployment_queues', function (Blueprint $table) {
$table->timestamp('finished_at')->nullable();
});
}
public function down()
{
Schema::table('application_deployment_queues', function (Blueprint $table) {
$table->dropColumn('finished_at');
});
}
};

View File

@@ -0,0 +1,38 @@
<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
return new class extends Migration
{
public function up()
{
Schema::table('application_deployment_queues', function (Blueprint $table) {
$table->timestamp('finished_at')->nullable();
});
Schema::table('scheduled_database_backup_executions', function (Blueprint $table) {
$table->timestamp('finished_at')->nullable();
});
Schema::table('scheduled_task_executions', function (Blueprint $table) {
$table->timestamp('finished_at')->nullable();
});
}
public function down()
{
Schema::table('application_deployment_queues', function (Blueprint $table) {
$table->dropColumn('finished_at');
});
Schema::table('scheduled_database_backup_executions', function (Blueprint $table) {
$table->dropColumn('finished_at');
});
Schema::table('scheduled_task_executions', function (Blueprint $table) {
$table->dropColumn('finished_at');
});
}
};