parfum/database/migrations/2025_09_24_141358_create_memberships_table.php
Yoga Pangestu 28c69dbf23 feat(membership): membuat curd dengan modal
-membuat action edit dengan modal
-menghapus sidebar yang tidak diperlukan
2025-09-25 19:24:41 +07:00

33 lines
783 B
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('memberships', function (Blueprint $table) {
$table->id();
$table->string('name', 50);
$table->text('terms_conditions')->nullable();
$table->unsignedInteger('min_purchase');
$table->decimal('discount_percentage', 5, 2);
$table->timestamps();
$table->softDeletes();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('memberships');
}
};