forms/migrations/UserMigration.php
2024-05-28 17:10:06 +03:00

30 lines
712 B
PHP
Executable File

<?php
namespace itguild\forms\form\migrations;
use Illuminate;
class UserMigration
{
public static function up(): void
{
Illuminate\Database\Capsule\Manager::schema()->create("user", function ($table) {
$table->increments('id');
$table->string('name');
$table->string('email')->unique();
$table->string('password');
$table->string('userimage')->nullable();
$table->string('api_key')->nullable()->unique();
$table->rememberToken();
$table->timestamps();
});
}
public static function down(): void
{
Illuminate\Database\Capsule\Manager::schema()->drop("user");
}
}