add booking_charge to booking table

This commit is contained in:
Edmond Teh
2020-09-25 16:26:38 +08:00
parent eac4336774
commit a3a6ee1f94
2 changed files with 33 additions and 1 deletions
+1 -1
View File
@@ -24,7 +24,7 @@ class Booking extends Model
"usd_book_bank_branch");
protected $fillable = ['id', 'term', 'rate_id', 'user_id', 'amount', 'account_name', 'account_num', 'bank_name',
'bank_branch', 'company_name', 'service_charge'];
'bank_branch', 'company_name', 'service_charge', 'billing_charge'];
public $timestamps = true;
@@ -0,0 +1,32 @@
<?php
use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
class AddBillingChargeToBookings extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::table('bookings', function (Blueprint $table) {
$table->double('billing_charge')->default(null)->nullable();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::table('bookings', function (Blueprint $table) {
$table->dropColumn('billing_charge');
});
}
}