increments('id'); $table->integer('application_id')->unsigned(); $table->string('status', 20)->default(LoanAgreementLog::STATUS_PENDING); // PENDING, APPROVED, REJECTED $table->integer('agreement_type_id')->unsigned()->index(); $table->integer('maker_id')->unsigned()->index(); $table->text('maker_reason'); $table->integer('checker_user_id')->unsigned()->nullable(); $table->text('checker_comments')->nullable(); $table->timestamps(); $table->index(['application_id', 'status']); $table->index('status'); }); } /** * Reverse the migrations. * * @return void */ public function down() { Schema::dropIfExists('loan_agreement_logs'); } }