change primary keys in migrations
This commit is contained in:
parent
df9b6ca6ed
commit
0f6e5b5737
|
@ -14,7 +14,7 @@ class CreateCountriesTable extends Migration
|
|||
public function up()
|
||||
{
|
||||
Schema::create('countries', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->id();
|
||||
$table->string('name');
|
||||
$table->string('nami_id')->nullable();
|
||||
});
|
||||
|
|
|
@ -14,7 +14,7 @@ class CreateGendersTable extends Migration
|
|||
public function up()
|
||||
{
|
||||
Schema::create('genders', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->id();
|
||||
$table->string('name');
|
||||
$table->boolean('is_null');
|
||||
$table->integer('nami_id');
|
||||
|
|
|
@ -14,7 +14,7 @@ class CreateRegionsTable extends Migration
|
|||
public function up()
|
||||
{
|
||||
Schema::create('regions', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->id();
|
||||
$table->string('name');
|
||||
$table->boolean('is_null');
|
||||
$table->integer('nami_id')->nullable();
|
||||
|
|
|
@ -14,7 +14,7 @@ class CreateConfessionsTable extends Migration
|
|||
public function up()
|
||||
{
|
||||
Schema::create('confessions', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->id();
|
||||
$table->string('name');
|
||||
$table->integer('nami_id')->nullable();
|
||||
$table->boolean('is_null');
|
||||
|
|
|
@ -14,8 +14,8 @@ class CreateWaysTable extends Migration
|
|||
public function up()
|
||||
{
|
||||
Schema::create('ways', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->string('title');
|
||||
$table->id();
|
||||
$table->string('title');
|
||||
});
|
||||
}
|
||||
|
||||
|
|
|
@ -14,7 +14,7 @@ class CreateNationalitiesTable extends Migration
|
|||
public function up()
|
||||
{
|
||||
Schema::create('nationalities', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->id();
|
||||
$table->string('name');
|
||||
$table->integer('nami_id');
|
||||
$table->timestamps();
|
||||
|
|
|
@ -14,7 +14,7 @@ class CreateActivitiesTable extends Migration
|
|||
public function up()
|
||||
{
|
||||
Schema::create('activities', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->id();
|
||||
$table->string('name');
|
||||
$table->integer('nami_id');
|
||||
});
|
||||
|
|
|
@ -14,13 +14,13 @@ class CreateMembershipsTable extends Migration
|
|||
public function up()
|
||||
{
|
||||
Schema::create('memberships', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->integer('activity_id');
|
||||
$table->integer('group_id')->nullable();
|
||||
$table->integer('member_id');
|
||||
$table->integer('nami_id')->nullable();
|
||||
$table->id();
|
||||
$table->integer('activity_id');
|
||||
$table->integer('group_id')->nullable();
|
||||
$table->integer('member_id');
|
||||
$table->integer('nami_id')->nullable();
|
||||
$table->timestamps();
|
||||
$table->unique(['activity_id', 'group_id', 'member_id', 'nami_id']);
|
||||
$table->unique(['activity_id', 'group_id', 'member_id', 'nami_id']);
|
||||
});
|
||||
}
|
||||
|
||||
|
|
|
@ -14,7 +14,7 @@ class CreateFeesTable extends Migration
|
|||
public function up()
|
||||
{
|
||||
Schema::create('fees', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->id();
|
||||
$table->string('name');
|
||||
$table->integer('nami_id');
|
||||
});
|
||||
|
|
|
@ -14,7 +14,7 @@ class CreateSubscriptionsTable extends Migration
|
|||
public function up()
|
||||
{
|
||||
Schema::create('subscriptions', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->id();
|
||||
$table->string('name');
|
||||
$table->timestamps();
|
||||
});
|
||||
|
|
|
@ -14,7 +14,7 @@ class CreateGroupsTable extends Migration
|
|||
public function up()
|
||||
{
|
||||
Schema::create('groups', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->id();
|
||||
$table->string('name');
|
||||
$table->string('nami_id')->nullable();
|
||||
});
|
||||
|
|
Loading…
Reference in New Issue