Skip to content
This repository has been archived by the owner on Aug 31, 2024. It is now read-only.

Commit

Permalink
According to MySQL unsigned types for forign keys
Browse files Browse the repository at this point in the history
  • Loading branch information
elnurxf authored Oct 16, 2020
1 parent 25a8010 commit 5bd6643
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions migrations/create_promocodes_table.php.stub
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ class CreatePromocodesTable extends Migration
public function up()
{
Schema::create('promocodes', function (Blueprint $table) {
$table->increments('id');
$table->id();

$table->string('code', 32)->unique();
$table->double('reward', 10, 2)->nullable();
Expand All @@ -26,7 +26,7 @@ class CreatePromocodesTable extends Migration
});

Schema::create('promocode_user', function (Blueprint $table) {
$table->increments('id');
$table->id();

$table->unsignedBigInteger('user_id');
$table->unsignedBigInteger('promocode_id');
Expand Down

0 comments on commit 5bd6643

Please sign in to comment.