id(); $table->foreignIdFor(Directorat::class)->constrained()->onDelete('cascade'); $table->foreignIdFor(SubDirectorat::class)->constrained()->onDelete('cascade'); $table->foreignIdFor(Job::class)->constrained()->onDelete('cascade'); $table->foreignIdFor(SubJob::class)->constrained()->onDelete('cascade'); $table->foreignIdFor(SubSubJob::class)->constrained()->onDelete('cascade'); $table->string('sequence', 100)->default(1); $table->string('sequence_dus', 100)->default(1); $table->string('sequence_odner', 100)->default(1); $table->string('kode', 10); $table->string('kode_dus', 6); $table->string('kode_odner', 8); $table->string('status')->default(0)->nullable(); $table->timestamps(); $table->timestamp('authorized_at')->nullable(); $table->softDeletes(); $table->unsignedBigInteger('created_by')->nullable(); $table->unsignedBigInteger('updated_by')->nullable(); $table->unsignedBigInteger('deleted_by')->nullable(); $table->unsignedBigInteger('authorized_by')->nullable(); }); } /** * Reverse the migrations. */ public function down() : void { Schema::dropIfExists('documents'); } };