admin-panel-zimbra-api/database/migrations/2024_04_15_034120_create_class_of_services_table.php
Nguyen Van Nguyen e9f0a9ec2c first commit
Signed-off-by: Nguyen Van Nguyen <nguyennv1981@gmail.com>
2024-04-22 14:45:23 +07:00

37 lines
1 KiB
PHP

<?php
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::create('class_of_services', function (Blueprint $table) {
$table->id();
$table->string('zimbra_id')->unique();
$table->string('name');
$table->unsignedInteger('mail_quota');
$table->unsignedMediumInteger('max_accounts');
$table->timestamp('zimbra_create')->nullable();
$table->text('description')->nullable();
$table->json('attributes')->nullable();
$table->unsignedInteger('created_by')->default(0)->index();
$table->unsignedInteger('updated_by')->default(0)->index();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('class_of_services');
}
};