Files
expense/database/migrations/2024_11_30_171010_create_menu_table.php
T

38 lines
944 B
PHP
Raw Normal View History

2024-12-02 01:18:34 +07:00
<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
return new class extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('menu', function (Blueprint $table) {
$table->bigInteger('id', false, true)->primary();
$table->string('title', 255);
$table->string('url', 255);
$table->string('icon', 255)->nullable();
$table->bigInteger('parent_id')->nullable();
$table->integer('order', false, true)->default(0);
$table->timestamp('created_at', 6)->nullable();
$table->timestamp('updated_at', 6)->nullable();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('menu');
}
};