Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,33 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
return new class extends Migration
|
||||
{
|
||||
public function up(): void
|
||||
{
|
||||
Schema::create('users', function (Blueprint $table) {
|
||||
$table->id();
|
||||
$table->string('name');
|
||||
$table->string('email')->unique();
|
||||
$table->timestamp('email_verified_at')->nullable();
|
||||
$table->string('password');
|
||||
$table->rememberToken();
|
||||
// Profil léger : locale/unités d'affichage, fuseau horaire, avatar média (RustFS/S3).
|
||||
$table->string('locale')->default('fr');
|
||||
$table->string('units')->default('metric'); // cast PHP Units (metric|imperial), pas d'enum SQL
|
||||
$table->string('timezone')->nullable();
|
||||
$table->string('avatar_path')->nullable();
|
||||
// Identifiant du compte côté fournisseur OIDC (pocket-id) : nullable tant que le login est mot de passe uniquement.
|
||||
$table->string('oidc_sub')->nullable()->unique();
|
||||
$table->timestamps();
|
||||
});
|
||||
}
|
||||
|
||||
public function down(): void
|
||||
{
|
||||
Schema::dropIfExists('users');
|
||||
}
|
||||
};
|
||||
Reference in New Issue
Block a user