id(); $table->foreignId('company_id')->constrained()->cascadeOnDelete(); $table->foreignId('account_id')->nullable()->constrained('accounts')->nullOnDelete(); $table->string('name')->nullable(); $table->text('description')->nullable(); $table->string('category')->default('tax'); $table->string('type')->default('sales'); $table->boolean('recoverable')->default(false); $table->integer('rate')->default(0); $table->string('computation')->default('percentage'); $table->string('scope')->nullable(); $table->dateTime('start_date')->nullable(); $table->dateTime('end_date')->nullable(); $table->foreignId('created_by')->nullable()->constrained('users')->nullOnDelete(); $table->foreignId('updated_by')->nullable()->constrained('users')->nullOnDelete(); $table->timestamps(); }); } /** * Reverse the migrations. */ public function down(): void { Schema::dropIfExists('adjustments'); } };