inventory datbase implementation

This commit is contained in:
BackwardsUser 2025-03-24 23:47:17 -04:00
parent 93f713e4ea
commit a90fba423a

View File

@ -0,0 +1,29 @@
<?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('inventory', function (Blueprint $table) {
$table->id(); // Auto-incrementing primary key
$table->string('name');
$table->text('description')->nullable();
$table->decimal('cost', 8, 2); // Max 999,999.99
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('inventory');
}
};