add prevent_overlapping_time_entries setting to organization

when enabled users are blocked from creating or editing new time entries that are overlapping with other time entries
This commit is contained in:
Gregor Vostrak
2025-10-03 14:58:21 +02:00
parent c0788c270b
commit 19a206d57c
14 changed files with 450 additions and 17 deletions

View File

@@ -0,0 +1,30 @@
<?php
declare(strict_types=1);
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
return new class extends Migration
{
/**
* Run the migrations.
*/
public function up(): void
{
Schema::table('organizations', function (Blueprint $table): void {
$table->boolean('prevent_overlapping_time_entries')->default(false)->after('employees_can_see_billable_rates');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('organizations', function (Blueprint $table): void {
$table->dropColumn('prevent_overlapping_time_entries');
});
}
};