partial update opnames and detail table

This commit is contained in:
2025-06-04 18:29:05 +07:00
parent 8305e44c42
commit ff498cd98f
20 changed files with 864 additions and 174 deletions

View File

@@ -0,0 +1,36 @@
<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreateOpnamesTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('opnames', function (Blueprint $table) {
$table->id();
$table->foreignId('dealer_id')->constrained()->onDelete('cascade');
$table->date('opname_date');
$table->foreignId('user_id')->constrained()->onDelete('cascade');
$table->text("note")->nullable();
$table->softDeletes();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('opnames');
}
}