<?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('tax_masters', function (Blueprint $table) {
            $table->id();
            $table->string('name', 255)->nullable();
            $table->string('description', 255)->nullable();
            $table->string('total_percentage', 255)->nullable();
            $table->string('calculation', 255)->nullable();
            $table->enum('default', ['0', '1'])->default('0');
            $table->decimal('priority')->nullable();
            $table->enum('status', ['0', '1'])->default('1');
            $table->unsignedBigInteger('tax_category_id')->nullable();
            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('tax_masters');
    }
};
