mirror of
https://gitlab.com/omair-personal/exchange.git
synced 2026-08-19 04:24:08 +00:00
update migration
This commit is contained in:
@@ -17,7 +17,7 @@ class CreatePurchaseOrdersTable extends Migration
|
||||
$table->increments('id');
|
||||
$table->string('image_url');
|
||||
$table->double('amount');
|
||||
$table->integer('book_id')->unsigned();
|
||||
$table->integer('book_id')->unsigned()->nullable;
|
||||
$table->foreign('book_id')->references('id')->on('bookings');
|
||||
$table->timestamps();
|
||||
});
|
||||
|
||||
@@ -17,7 +17,7 @@ class RenameBookingForeignkeyInPoTable extends Migration
|
||||
{
|
||||
$table->dropForeign(['book_id']);
|
||||
$table->dropColumn('book_id');
|
||||
$table->integer('booking_id')->unsigned();
|
||||
$table->integer('booking_id')->unsigned()->nullable();
|
||||
$table->foreign('booking_id')->references('id')->on('bookings');
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user