first commit
This commit is contained in:
21
database/factories/ModelFactory.php
Normal file
21
database/factories/ModelFactory.php
Normal file
@@ -0,0 +1,21 @@
|
||||
<?php
|
||||
/*
|
||||
|-------------------------------------------------------------------
|
||||
| Models Factories
|
||||
|-------------------------------------------------------------------
|
||||
|
|
||||
| Here you may define all of your model factories. Models factories
|
||||
| give you a convenient way to create models for testing and seeding
|
||||
| your database. Just tell the factory how a default model should
|
||||
| look.
|
||||
*/
|
||||
|
||||
use Illuminate\Support\Facades\Hash;
|
||||
|
||||
$factory->define(App\Models\Users::class, function (Faker\Generator $faker) {
|
||||
return [
|
||||
'name' => $faker->name,
|
||||
'email' => $faker->unique()->email,
|
||||
'password' => Hash::make('12345'),
|
||||
];
|
||||
});
|
||||
0
database/migrations/.gitkeep
Normal file
0
database/migrations/.gitkeep
Normal file
51
database/migrations/2019_09_17_103201_create_user_table.php
Normal file
51
database/migrations/2019_09_17_103201_create_user_table.php
Normal file
@@ -0,0 +1,51 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreateUserTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('user', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->string('gender',1);
|
||||
$table->string('name', 255);
|
||||
$table->string('surname',255);
|
||||
$table->char('email',128);
|
||||
$table->string('password',255);
|
||||
$table->string('phone',100)->nullable();
|
||||
$table->integer('user_type')->default(1);
|
||||
$table->string('locale',2)->default('en');
|
||||
$table->tinyInteger('status')->default(0)->index();
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::table('user', function (Blueprint $table) {
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
$table->unique('email');
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('user');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,68 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreateLanguageTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
|
||||
Schema::create('language', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->string('code', 2);
|
||||
$table->string('name', 45);
|
||||
$table->tinyInteger('status')->default(1)->index();
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::table('language', function (Blueprint $table) {
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
$table->unique('code');
|
||||
});
|
||||
|
||||
|
||||
Schema::create('language_locale', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->string('language_code',2);
|
||||
$table->string('name', 45);
|
||||
$table->string('locale',2);
|
||||
$table->tinyInteger('status')->default(1)->index();
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
|
||||
});
|
||||
|
||||
Schema::table('language_locale', function (Blueprint $table) {
|
||||
$table->foreign('language_code')->references('code')->on('language');
|
||||
$table->foreign('locale')->references('code')->on('language');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
$table->unique(['language_code','locale']);
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('language_locale');
|
||||
Schema::dropIfExists('language');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,42 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePropertyChainTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('property_chain', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->string('name',100);
|
||||
$table->string('loyalty',30)->nullable();
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::table('property_chain',function (Blueprint $table) {
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('property_chain');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,66 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreateCurrencyTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('currency', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->string('code', 3)->unique();
|
||||
$table->string('name', 45);
|
||||
|
||||
$table->tinyInteger('status')->default(1)->index();
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::table('currency', function (Blueprint $table) {
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
});
|
||||
|
||||
Schema::create('currency_locale', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->string('currency_code', 3);
|
||||
$table->string('name', 45);
|
||||
$table->string('locale', 2);
|
||||
|
||||
$table->tinyInteger('status')->default(1)->index();
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
|
||||
});
|
||||
Schema::table('currency_locale', function (Blueprint $table) {
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
$table->foreign('currency_code')->references('code')->on('currency');
|
||||
$table->foreign('locale')->references('code')->on('language');
|
||||
$table->unique(['currency_code','locale']);
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('currency_locale');
|
||||
Schema::dropIfExists('currency');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,64 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePropertyTypeTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('property_type', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->string('name',200);
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
|
||||
Schema::create('property_type_locale', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->unsignedInteger('type_id');
|
||||
$table->string('name',200);
|
||||
$table->string('locale',2);
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
/**
|
||||
* Table Relations
|
||||
*/
|
||||
Schema::table('property_type',function (Blueprint $table) {
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
});
|
||||
|
||||
Schema::table('property_type_locale',function (Blueprint $table) {
|
||||
$table->foreign('type_id')->references('id')->on('property_type');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('property_type_locale');
|
||||
Schema::dropIfExists('property_type');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,55 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePropertyTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('property', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->string('name',255);
|
||||
$table->unsignedInteger('destination_id')->nullable();
|
||||
$table->unsignedInteger('property_type_id')->nullable();
|
||||
$table->unsignedInteger('chain_id')->nullable();
|
||||
$table->double('rating')->nullable();
|
||||
$table->string('official_name',255)->nullable();
|
||||
$table->string('tax_office',255)->nullable();
|
||||
$table->string('tax_number',255)->nullable();
|
||||
$table->string('currency_type', 3)->nullable();
|
||||
$table->string('checkin_time', 50)->nullable();
|
||||
$table->string('checkout_time', 50)->nullable();
|
||||
$table->tinyInteger('status')->default(1)->index();
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::table('property', function (Blueprint $table) {
|
||||
|
||||
$table->foreign('property_type_id')->references('id')->on('property_type');
|
||||
$table->foreign('chain_id')->references('id')->on('property_chain');
|
||||
$table->foreign('currency_type')->references('code')->on('currency');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('property');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,41 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreateTempPropertyTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('temp_property', function (Blueprint $table) {
|
||||
$table->integerIncrements('id');
|
||||
$table->string('name',255);
|
||||
$table->integer('destination_id');
|
||||
//TODO: Giata_id int mi olacak string mi olacak.
|
||||
$table->string('giata_id',50);
|
||||
$table->tinyInteger('status')->default(1)->index();
|
||||
$table->unsignedInteger('created_by')->nullable();
|
||||
$table->unsignedInteger('updated_by')->nullable();
|
||||
$table->integer('created_at')->nullable();
|
||||
$table->integer('updated_at')->nullable();
|
||||
});
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('temp_property');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,46 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreateUserPropertyMappingTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('user_property_mapping', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->unsignedInteger('user_id');
|
||||
$table->unsignedInteger('property_id');
|
||||
$table->tinyInteger('status')->default(1)->index();
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
|
||||
Schema::table('user_property_mapping', function (Blueprint $table) {
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
$table->foreign('user_id')->references('id')->on('user');
|
||||
$table->foreign('property_id')->references('id')->on('property');
|
||||
$table->unique(['user_id','property_id']);
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('user_property_mapping');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,65 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePropertyContentCategoryTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('property_content_category', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->string('name');
|
||||
$table->tinyInteger('status');
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::table('property_content_category', function (Blueprint $table) {
|
||||
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
});
|
||||
|
||||
Schema::create('property_content_category_locale', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->unsignedInteger('content_category_id');
|
||||
$table->string('name');
|
||||
$table->string('locale',2);
|
||||
$table->tinyInteger('status');
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::table('property_content_category_locale', function (Blueprint $table) {
|
||||
|
||||
$table->foreign('content_category_id')->references('id')->on('property_content_category');
|
||||
$table->foreign('locale')->references('code')->on('language');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
$table->unique(['content_category_id', 'locale'],'language_unique');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('property_content_category_locale');
|
||||
|
||||
Schema::dropIfExists('property_content_category');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,52 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePropertyContentTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('property_content', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->unsignedInteger('property_id');
|
||||
$table->unsignedInteger('content_category_id');
|
||||
$table->mediumText('content')->nullable();
|
||||
$table->string('locale',2);
|
||||
$table->tinyInteger('status');
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::table('property_content', function (Blueprint $table) {
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
$table->foreign('property_id')->references('id')->on('property');
|
||||
$table->foreign('content_category_id')->references('id')->on('property_content_category');
|
||||
$table->foreign('locale')->references('code')->on('language');
|
||||
$table->unique(['property_id', 'content_category_id', 'locale'],'content_unique');
|
||||
});
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
|
||||
Schema::dropIfExists('property_content');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,68 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePropertyFactTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('property_fact', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->string('name','250');
|
||||
$table->integer('parent_id',false,true)->nullable();
|
||||
$table->tinyInteger('type')->default(0);
|
||||
$table->tinyInteger('order_number')->default(0);
|
||||
$table->string('icon')->nullable();
|
||||
$table->tinyInteger('status',false,true)->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::create('property_fact_locale', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->unsignedInteger('fact_id');
|
||||
$table->string('name');
|
||||
$table->string('locale',2);
|
||||
$table->tinyInteger('status');
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
/**
|
||||
* Table Relations
|
||||
*/
|
||||
Schema::table('property_fact',function (Blueprint $table) {
|
||||
$table->foreign('parent_id')->references('id')->on('property_fact');
|
||||
});
|
||||
|
||||
Schema::table('property_fact_locale',function (Blueprint $table) {
|
||||
$table->foreign('fact_id')->references('id')->on('property_fact');
|
||||
$table->foreign('locale')->references('code')->on('language');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
$table->unique(['fact_id', 'locale'],'pfl_language_unique');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('property_fact_locale');
|
||||
Schema::dropIfExists('property_fact');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,60 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePropertyUnitTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('property_unit', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->string('name',100);
|
||||
$table->string('short_name',45);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::create('property_unit_locale', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->unsignedInteger('unit_id');
|
||||
$table->string('name');
|
||||
$table->string('locale',2);
|
||||
$table->tinyInteger('status');
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
/**
|
||||
* Table Relation
|
||||
*/
|
||||
Schema::table('property_unit_locale',function (Blueprint $table) {
|
||||
$table->foreign('unit_id')->references('id')->on('property_unit');
|
||||
$table->foreign('locale')->references('code')->on('language');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
$table->unique(['unit_id', 'locale'],'pul_language_unique');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('property_unit_locale');
|
||||
Schema::dropIfExists('property_unit');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,69 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePropertyFactAttributeTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('property_fact_attribute', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->string('name','250');
|
||||
$table->integer('unit_id',false,true)->default(0);
|
||||
$table->tinyInteger('type')->default(0);
|
||||
$table->tinyInteger('order_number')->default(0);
|
||||
$table->tinyInteger('status',false,true)->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
|
||||
Schema::create('property_fact_attribute_locale', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->unsignedInteger('attribute_id');
|
||||
$table->string('name');
|
||||
$table->string('locale',2);
|
||||
$table->tinyInteger('status');
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
/**
|
||||
* Table Relations
|
||||
*/
|
||||
|
||||
Schema::table('property_fact_attribute',function (Blueprint $table) {
|
||||
$table->foreign('unit_id')->references('id')->on('property_unit');
|
||||
});
|
||||
|
||||
Schema::table('property_fact_attribute_locale',function (Blueprint $table) {
|
||||
$table->foreign('attribute_id')->references('id')->on('property_fact_attribute');
|
||||
$table->foreign('locale')->references('code')->on('language');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
$table->unique(['attribute_id', 'locale'],'pfal_language_unique');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('property_fact_attribute_locale');
|
||||
Schema::dropIfExists('property_fact_attribute');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,41 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePropertyFactAttributeMappingTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('property_fact_attribute_mapping', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->integer('fact_id')->unsigned();
|
||||
$table->integer('attribute_id')->unsigned();
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::table('property_fact_attribute_mapping',function (Blueprint $table) {
|
||||
$table->foreign('fact_id')->references('id')->on('property_fact');
|
||||
$table->foreign('attribute_id')->references('id')->on('property_fact_attribute');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('property_fact_attribute_mapping');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,47 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePropertyFactMappingTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('property_fact_mapping', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->integer('property_id')->unsigned();
|
||||
$table->integer('fact_id')->unsigned();
|
||||
$table->integer('attribute_id')->unsigned()->nullable();
|
||||
$table->integer('unit_id')->unsigned()->nullable();
|
||||
$table->string('value',100)->nullable()->default(null);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::table('property_fact_mapping',function (Blueprint $table) {
|
||||
$table->foreign('property_id')->references('id')->on('property');
|
||||
$table->foreign('fact_id')->references('id')->on('property_fact');
|
||||
$table->foreign('attribute_id')->references('id')->on('property_fact_attribute');
|
||||
$table->foreign('unit_id')->references('id')->on('property_unit');
|
||||
$table->unique(['property_id', 'fact_id','attribute_id'],'pfam_unique');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('property_fact_mapping');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,56 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePropertyContactTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('property_contact', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->integer('property_id')->unsigned();
|
||||
$table->string('phone',50)->nullable();
|
||||
$table->string('phone_code',10)->nullable();
|
||||
$table->string('mobile',50)->nullable();
|
||||
$table->string('mobile_code',10)->nullable();
|
||||
$table->string('fax',50)->nullable();
|
||||
$table->string('fax_code',10)->nullable();
|
||||
$table->string('email',100)->nullable();
|
||||
$table->integer('destination_id')->unsigned();
|
||||
$table->string('web',100)->nullable();
|
||||
$table->string('zip_code',20)->nullable();
|
||||
$table->string('address',200)->nullable();
|
||||
$table->double('latitude',10,6)->nullable();
|
||||
$table->double('longitude',10,6)->nullable();
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::table('property_contact',function (Blueprint $table) {
|
||||
$table->foreign('property_id')->references('id')->on('property');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
$table->unique(['property_id'],'pc_unique');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('property_contact');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,64 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePropertyExecutiveTypeTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('property_executive_type', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->string('name',200);
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::create('property_executive_type_locale', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->unsignedInteger('executive_id');
|
||||
$table->string('name',200);
|
||||
$table->string('locale',2);
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
/**
|
||||
* Table Relations
|
||||
*/
|
||||
Schema::table('property_executive_type',function (Blueprint $table) {
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
});
|
||||
|
||||
Schema::table('property_executive_type_locale',function (Blueprint $table) {
|
||||
$table->foreign('executive_id')->references('id')->on('property_executive_type');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('property_executive_type_locale');
|
||||
Schema::dropIfExists('property_executive_type');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,53 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePropertyExecutiveTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('property_executive', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->unsignedInteger('property_id');
|
||||
$table->unsignedInteger('executive_type_id');
|
||||
$table->string('name_surname',200)->nullable();
|
||||
$table->string('email',100)->nullable();
|
||||
$table->string('phone_code',10)->nullable();
|
||||
$table->string('phone',50)->nullable();
|
||||
$table->string('mobile_code',10)->nullable();
|
||||
$table->string('mobile',50)->nullable();
|
||||
$table->string('fax_code',10)->nullable();
|
||||
$table->string('fax',50)->nullable();
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::table('property_executive',function (Blueprint $table) {
|
||||
$table->foreign('property_id')->references('id')->on('property');
|
||||
$table->foreign('executive_type_id')->references('id')->on('property_executive_type');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
$table->unique(['property_id', 'executive_type_id']);
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('property_executive');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,63 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePropertyAdditionalInfoKeyTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('property_additional_info_key', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->string('additional_info_key',100);
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::create('property_additional_info_key_locale', function (Blueprint $table) {
|
||||
|
||||
$table->increments('id');
|
||||
$table->unsignedInteger('additional_info_key_id');
|
||||
$table->string('additional_info_key',200);
|
||||
$table->string('locale',2);
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::table('property_additional_info_key', function (Blueprint $table) {
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
$table->unique(['additional_info_key'],'padilk_unique');
|
||||
});
|
||||
|
||||
Schema::table('property_additional_info_key_locale', function (Blueprint $table) {
|
||||
$table->foreign('additional_info_key_id','paikl_additional_info_key_id_fk')->references('id')->on('property_additional_info_key');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
$table->unique(['additional_info_key_id','locale'],'padilkl_unique');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('property_additional_info_key_locale');
|
||||
Schema::dropIfExists('property_additional_info_key');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,46 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePropertyAdditionalInfoTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('property_additional_info', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->unsignedInteger('property_id');
|
||||
$table->unsignedInteger('additional_info_key_id');
|
||||
$table->string('value',100)->nullable();
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::table('property_additional_info',function (Blueprint $table){
|
||||
$table->foreign('property_id')->references('id')->on('property');
|
||||
$table->foreign('additional_info_key_id')->references('id')->on('property_additional_info_key');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
$table->unique(['property_id','additional_info_key_id' ],'pai_unique');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('property_additional_info');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,135 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePropertyPhotoTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('property_photo', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->unsignedInteger('property_id');
|
||||
$table->unsignedInteger('property_photo_category_id')->nullable();
|
||||
$table->string('photo_path');
|
||||
$table->string('photo_name',200);
|
||||
$table->double('photo_rank')->nullable();
|
||||
$table->string('file_size')->nullable();
|
||||
$table->string('file_ext')->nullable();
|
||||
$table->string('photo_resolution')->nullable();
|
||||
$table->integer('photo_order')->nullable();
|
||||
$table->tinyInteger('is_default')->default(0);
|
||||
$table->tinyInteger('is_temp')->default(1);
|
||||
$table->tinyInteger('status',false,true)->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::create('property_photo_category', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->string('category_name',50)->unique();
|
||||
$table->tinyInteger('status',false,true)->default(0);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::create('property_photo_category_locale', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->unsignedInteger('property_photo_category_id');
|
||||
$table->string('category_name');
|
||||
$table->string('locale',2);
|
||||
$table->tinyInteger('status',false,true)->default(0);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::create('photo_google_label', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->string('label', 50)->unique();
|
||||
$table->tinyInteger('status',false,true)->default(0);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::create('property_photo_category_label_mapping', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->unsignedInteger('property_photo_category_id');
|
||||
$table->unsignedInteger('photo_google_label_id');
|
||||
$table->tinyInteger('status',false,true)->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
|
||||
/**
|
||||
* Table Relations
|
||||
*/
|
||||
Schema::table('property_photo',function (Blueprint $table) {
|
||||
$table->foreign('property_id')->references('id')->on('property');
|
||||
$table->foreign('property_photo_category_id','pp_property_photo_category_id')->references('id')->on('property_photo_category');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
|
||||
});
|
||||
|
||||
/**
|
||||
* Table Relations
|
||||
*/
|
||||
Schema::table('property_photo_category_label_mapping',function (Blueprint $table) {
|
||||
$table->foreign('property_photo_category_id','ppclm_property_photo_category_id')->references('id')->on('property_photo_category');
|
||||
$table->foreign('photo_google_label_id','ppclm_photo_google_label_id')->references('id')->on('photo_google_label');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
});
|
||||
|
||||
/**
|
||||
* Table Relations
|
||||
*/
|
||||
Schema::table('property_photo_category',function (Blueprint $table) {
|
||||
$table->unique('category_name','pr_ph_ctg_name');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
});
|
||||
|
||||
/**
|
||||
* Table Relations
|
||||
*/
|
||||
Schema::table('property_photo_category_locale',function (Blueprint $table) {
|
||||
$table->foreign('property_photo_category_id','ppcl_property_photo_category_id')->references('id')->on('property_photo_category');
|
||||
$table->unique(['property_photo_category_id', 'locale'],'ppcl_category_id_locale');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('property_photo');
|
||||
Schema::dropIfExists('property_photo_category_label_mapping');
|
||||
Schema::dropIfExists('property_photo_category_locale');
|
||||
Schema::dropIfExists('property_photo_category');
|
||||
Schema::dropIfExists('photo_google_label');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,46 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePropertyConfigTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('property_config', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->unsignedInteger('property_id');
|
||||
$table->string('config_key',64);
|
||||
$table->text('config_value_json') ;
|
||||
$table->tinyInteger('status');
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
|
||||
Schema::table('property_config', function (Blueprint $table) {
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
$table->foreign('property_id')->references('id')->on('property');
|
||||
$table->unique(['property_id', 'config_key'],'config_unique');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('property_config');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,64 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePropertyModuleTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('property_module', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->string('name',200);
|
||||
$table->tinyInteger('point')->nullable();
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::table('property_module',function (Blueprint $table) {
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
});
|
||||
|
||||
|
||||
Schema::create('property_module_mapping', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->unsignedInteger('property_module_id');
|
||||
$table->unsignedInteger('property_id');
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::table('property_module_mapping',function (Blueprint $table) {
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
$table->foreign('property_id')->references('id')->on('property');
|
||||
$table->foreign('property_module_id')->references('id')->on('property_module');
|
||||
|
||||
$table->unique(['property_module_id','property_id'], 'mapping_unique');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('property_module_mapping');
|
||||
Schema::dropIfExists('property_module');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,133 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePermissionTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('permission', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->string('name',128);
|
||||
$table->string('code',128)->unique();
|
||||
$table->unsignedInteger('parent_id')->nullable();
|
||||
$table->tinyInteger('is_menu')->nullable()->default(0);
|
||||
$table->string('menu_detail', 255)->nullable();
|
||||
$table->tinyInteger('menu_order')->nullable()->default(0);
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::table('permission',function (Blueprint $table) {
|
||||
$table->foreign('parent_id')->references('id')->on('permission');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
|
||||
});
|
||||
|
||||
Schema::create('permission_group', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->string('name',128);
|
||||
$table->tinyInteger('is_admin')->nullable()->default(0);
|
||||
$table->string('parameter_rules', 255)->nullable();
|
||||
$table->tinyInteger('is_private_permission')->nullable();
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::table('permission_group',function (Blueprint $table) {
|
||||
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
|
||||
});
|
||||
|
||||
Schema::create('permission_group_mapping', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->unsignedInteger('permission_group_id');
|
||||
$table->unsignedInteger('permission_id');
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::table('permission_group_mapping',function (Blueprint $table) {
|
||||
$table->foreign('permission_group_id')->references('id')->on('permission_group');
|
||||
$table->foreign('permission_id')->references('id')->on('permission');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
$table->unique(['permission_group_id', 'permission_id'], 'pgm_unique');
|
||||
});
|
||||
|
||||
Schema::create('permission_group_user_mapping', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->unsignedInteger('property_id');
|
||||
$table->unsignedInteger('user_id');
|
||||
$table->unsignedInteger('permission_group_id');
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::table('permission_group_user_mapping',function (Blueprint $table) {
|
||||
$table->foreign('permission_group_id')->references('id')->on('permission_group');
|
||||
$table->foreign('property_id')->references('id')->on('property');
|
||||
$table->foreign('user_id')->references('id')->on('user');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
$table->unique(['permission_group_id', 'property_id', 'user_id'], 'pgu_unique');
|
||||
|
||||
});
|
||||
|
||||
Schema::create('permission_locale', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->unsignedInteger('permission_id');
|
||||
$table->string('name',128);
|
||||
$table->string('locale',2);
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::table('permission_locale', function (Blueprint $table) {
|
||||
$table->foreign('permission_id')->references('id')->on('permission');
|
||||
$table->foreign('locale')->references('code')->on('language');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
$table->unique(['permission_id', 'locale'],'language_unique');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('permission_group_user_mapping');
|
||||
Schema::dropIfExists('permission_group_mapping');
|
||||
Schema::dropIfExists('permission_group');
|
||||
Schema::dropIfExists('permission_locale');
|
||||
Schema::dropIfExists('permission');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,40 @@
|
||||
<<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreateApiAccessTokenTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('api_access_token', function (Blueprint $table) {
|
||||
$table->bigIncrements('id');
|
||||
$table->string('token','64')->unique();
|
||||
$table->integer('expire_date');
|
||||
$table->unsignedInteger('user_id');
|
||||
$table->tinyInteger('invalidate');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::table('api_access_token',function (Blueprint $table) {
|
||||
$table->foreign('user_id')->references('id')->on('user');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('api_access_token');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,34 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class AddHashKeyToUser extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::table('user', function (Blueprint $table) {
|
||||
|
||||
$table->string('hash_key', 255)->after('locale');
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::table('user', function (Blueprint $table) {
|
||||
$table->dropColumn(['hash_key']);
|
||||
});
|
||||
}
|
||||
}
|
||||
47
database/migrations/2019_11_15_151514_create_jobs_table.php
Normal file
47
database/migrations/2019_11_15_151514_create_jobs_table.php
Normal file
@@ -0,0 +1,47 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreateJobsTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('jobs', function (Blueprint $table) {
|
||||
$table->bigIncrements('id');
|
||||
$table->string('queue');
|
||||
$table->longText('payload');
|
||||
$table->tinyInteger('attempts')->unsigned();
|
||||
$table->unsignedInteger('reserved_at')->nullable();
|
||||
$table->unsignedInteger('available_at');
|
||||
$table->unsignedInteger('created_at');
|
||||
$table->index(['queue', 'reserved_at']);
|
||||
});
|
||||
|
||||
Schema::create('failed_jobs', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->text('connection');
|
||||
$table->text('queue');
|
||||
$table->longText('payload');
|
||||
$table->longText('exception');
|
||||
$table->timestamp('failed_at')->useCurrent();
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('jobs');
|
||||
Schema::dropIfExists('failed_jobs');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,45 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreateSiteConfigTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('site_config', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->string('config_key',64);
|
||||
$table->text('config_value_json') ;
|
||||
$table->string('key_comment',64)->nullable();
|
||||
$table->tinyInteger('status');
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
|
||||
Schema::table('site_config', function (Blueprint $table) {
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
$table->unique(['config_key'],'config_unique');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('site_config');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,68 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePropertyRoomTypeTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('property_room_type', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->string('name',255);
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
|
||||
Schema::create('property_room_type_locale', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->unsignedInteger('room_type_id');
|
||||
$table->string('name',255);
|
||||
$table->string('locale',2);
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
|
||||
/***************
|
||||
* Table Relations
|
||||
****************/
|
||||
Schema::table('property_room_type',function (Blueprint $table) {
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
});
|
||||
|
||||
Schema::table('property_room_type_locale',function (Blueprint $table) {
|
||||
$table->foreign('room_type_id')->references('id')->on('property_room_type');
|
||||
$table->foreign('locale')->references('code')->on('language');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
$table->unique(['room_type_id','locale'],'prt_locale_unique');
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('property_room_type_locale');
|
||||
Schema::dropIfExists('property_room_type');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,50 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePropertyRoomTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('property_room', function (Blueprint $table) {
|
||||
$table->bigIncrements('id');
|
||||
$table->unsignedInteger('property_id');
|
||||
$table->string('name', 200);
|
||||
$table->mediumText('description')->nullable();
|
||||
$table->unsignedInteger('room_type_id');
|
||||
$table->integer('max_occupancy');
|
||||
$table->integer('max_adult');
|
||||
$table->integer('max_child');
|
||||
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
$table->foreign('room_type_id')->references('id')->on('property_room_type');
|
||||
$table->foreign('property_id')->references('id')->on('property');
|
||||
});
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('property_room');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,58 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePropertyRoomBedTypeTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('property_room_bed_type', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->string('name',200);
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
});
|
||||
|
||||
Schema::create('property_room_bed_type_locale', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->unsignedInteger('bed_type_id');
|
||||
$table->string('name',255);
|
||||
$table->string('locale',2);
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
|
||||
$table->foreign('bed_type_id')->references('id')->on('property_room_bed_type');
|
||||
$table->foreign('locale')->references('code')->on('language');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
$table->unique(['bed_type_id','locale'],'pbt_locale_unique');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('property_room_bed_type_locale');
|
||||
Schema::dropIfExists('property_room_bed_type');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,45 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePropertyRoomBedTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('property_room_bed', function (Blueprint $table) {
|
||||
$table->bigIncrements('id');
|
||||
$table->unsignedBigInteger('room_id');
|
||||
$table->tinyInteger('bed_group');
|
||||
$table->tinyInteger('count');
|
||||
$table->unsignedInteger('bed_type_id');
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
$table->foreign('room_id')->references('id')->on('property_room');
|
||||
$table->foreign('bed_type_id')->references('id')->on('property_room_bed_type');
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('property_room_bed');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,59 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePropertyChannelCategoryTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('property_channel_category', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->string('name',200);
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
});
|
||||
|
||||
|
||||
Schema::create('property_channel_category_locale', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->unsignedInteger('channel_category_id');
|
||||
$table->string('name',255);
|
||||
$table->string('locale',2);
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
|
||||
$table->foreign('channel_category_id')->references('id')->on('property_channel_category');
|
||||
$table->foreign('locale')->references('code')->on('language');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('property_channel_category_locale');
|
||||
Schema::dropIfExists('property_channel_category');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,47 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePropertyChannelTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('property_channel', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->string('name', 200);
|
||||
$table->mediumText('description');
|
||||
$table->string('type', 5);
|
||||
$table->unsignedInteger('channel_category_id');
|
||||
$table->string('country_code', 5)->nullable();
|
||||
$table->string('currency_code', 3);
|
||||
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
$table->foreign('channel_category_id')->references('id')->on('property_channel_category');
|
||||
$table->foreign('currency_code')->references('code')->on('currency');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('property_channel');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,44 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePropertyChannelMappingTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('property_channel_mapping', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->unsignedInteger('property_id');
|
||||
$table->unsignedInteger('channel_id');
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
$table->foreign('property_id')->references('id')->on('property');
|
||||
$table->foreign('channel_id')->references('id')->on('property_channel');
|
||||
$table->unique(['property_id', 'channel_id'], 'property_channel_unique');
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('property_channel_mapping');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,45 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePropertyRoomRateTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('property_room_rate', function (Blueprint $table) {
|
||||
$table->bigIncrements('id');
|
||||
$table->unsignedInteger('property_id');
|
||||
$table->string('name',200);
|
||||
$table->mediumText('description');
|
||||
$table->tinyInteger('min_stay');
|
||||
$table->tinyInteger('is_manually_input');
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
$table->foreign('property_id')->references('id')->on('property');
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('property_room_rate');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,50 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePropertyRoomRateMappingTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('property_room_rate_mapping', function (Blueprint $table) {
|
||||
$table->bigIncrements('id');
|
||||
$table->unsignedBigInteger('room_id');
|
||||
$table->unsignedBigInteger('room_rate_id');
|
||||
$table->mediumText('description');
|
||||
$table->double('rack_rate',10,2);
|
||||
$table->tinyInteger('included_occupancy');
|
||||
$table->tinyInteger('independent_availability');
|
||||
$table->tinyInteger('default_stop_sell');
|
||||
$table->tinyInteger('booking_on_request');
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
$table->foreign('room_id')->references('id')->on('property_room');
|
||||
$table->foreign('room_rate_id')->references('id')->on('property_room_rate');
|
||||
$table->unique(['room_id', 'room_rate_id'], 'room_room_rate_mapping');
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('property_room_rate_mapping');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,43 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePropertyRoomRateInclusionMappingTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('property_room_rate_inclusion_mapping', function (Blueprint $table) {
|
||||
$table->bigIncrements('id');
|
||||
$table->unsignedBigInteger('room_rate_id');
|
||||
$table->unsignedInteger('fact_id');
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
$table->foreign('room_rate_id')->references('id')->on('property_room_rate');
|
||||
$table->foreign('fact_id')->references('id')->on('property_fact');
|
||||
$table->unique(['room_rate_id', 'fact_id'], 'room_rate_fact_unique');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('property_room_rate_inclusion_mapping');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,44 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePropertyRoomRateChannelMappingTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('property_room_rate_channel_mapping', function (Blueprint $table) {
|
||||
$table->bigIncrements('id');
|
||||
$table->unsignedInteger('channel_id');
|
||||
$table->unsignedBigInteger('room_rate_mapping_id');
|
||||
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
$table->foreign('channel_id')->references('id')->on('property_channel');
|
||||
$table->foreign('room_rate_mapping_id')->references('id')->on('property_room_rate_mapping');
|
||||
$table->unique(['channel_id', 'room_rate_mapping_id'], 'room_rate_channel_unique');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('property_room_rate_channel_mapping');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,47 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePropertyRoomRateMappingSetupTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('property_room_rate_mapping_setup', function (Blueprint $table) {
|
||||
$table->bigIncrements('id');
|
||||
$table->unsignedBigInteger('room_rate_mapping_id');
|
||||
$table->string('setup_type', 100)->comment('EXT_ADULT, EXT_CHILD, DIS_GUEST');
|
||||
$table->string('value_type', 100)->comment('FIX, PER');
|
||||
$table->double('value', 10,2);
|
||||
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
$table->foreign('room_rate_mapping_id')->references('id')->on('property_room_rate_mapping');
|
||||
$table->unique(['room_rate_mapping_id', 'setup_type'], 'room_rate_setup_unique');
|
||||
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('property_room_rate_mapping_setup');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,57 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePropertyRoomRatePriceTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('property_room_rate_price', function (Blueprint $table) {
|
||||
$table->bigIncrements('id');
|
||||
$table->unsignedInteger('property_id');
|
||||
$table->unsignedBigInteger('property_room_id');
|
||||
$table->unsignedBigInteger('room_rate_mapping_id');
|
||||
$table->unsignedBigInteger('offer_id')->nullable();
|
||||
$table->unsignedInteger('channel_id')->nullable();
|
||||
$table->tinyInteger('min_stay');
|
||||
$table->tinyInteger('max_stay');
|
||||
$table->tinyInteger('stop_sell');
|
||||
$table->tinyInteger('booking_on_request');
|
||||
$table->date('date');
|
||||
$table->double('amount',10,2);
|
||||
$table->string('currency',3);
|
||||
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
$table->foreign('property_id')->references('id')->on('property');
|
||||
$table->foreign('property_room_id')->references('id')->on('property_room');
|
||||
$table->foreign('room_rate_mapping_id')->references('id')->on('property_room_rate_mapping');
|
||||
$table->foreign('channel_id')->references('id')->on('property_channel');
|
||||
$table->foreign('currency')->references('code')->on('currency');
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('property_room_rate_price');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,47 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePropertyRoomAvailabilityTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('property_room_availability', function (Blueprint $table) {
|
||||
$table->bigIncrements('id');
|
||||
$table->unsignedInteger('property_id');
|
||||
$table->unsignedBigInteger('property_room_id');
|
||||
$table->unsignedBigInteger('room_rate_mapping_id')->nullable();
|
||||
$table->unsignedBigInteger('offer_id')->nullable();
|
||||
$table->date('date');
|
||||
$table->integer('availability')->nullable();
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
$table->foreign('property_id')->references('id')->on('property');
|
||||
$table->foreign('property_room_id')->references('id')->on('property_room');
|
||||
$table->foreign('room_rate_mapping_id')->references('id')->on('property_room_rate_mapping');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('property_room_availability');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,32 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class AddMaxStayToPropertyRoomRate extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::table('property_room_rate', function (Blueprint $table) {
|
||||
$table->tinyInteger('max_stay')->after('min_stay');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::table('property_room_rate', function (Blueprint $table) {
|
||||
$table->dropColumn(['max_stay']);
|
||||
});
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,32 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class AddImageToPropertyChannel extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::table('property_channel', function (Blueprint $table) {
|
||||
$table->string('image', 255)->after('currency_code')->nullable();
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::table('property_channel', function (Blueprint $table) {
|
||||
$table->dropColumn(['image']);
|
||||
});
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,44 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class DropUniqueToPropertyExecutive extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
|
||||
// drop all index and forigns ...daha önce eklenene unique keyin kaldırılamamsı sebebi ile ...
|
||||
Schema::table('property_executive', function (Blueprint $table) {
|
||||
$table->dropForeign('property_executive_ibfk_1');
|
||||
$table->dropForeign('property_executive_ibfk_2');
|
||||
$table->dropForeign('property_executive_ibfk_3');
|
||||
$table->dropForeign('property_executive_ibfk_4');
|
||||
$table->dropIndex('property_executive_updated_by_foreign');
|
||||
$table->dropIndex('property_executive_created_by_foreign');
|
||||
$table->dropIndex('property_executive_executive_type_id_foreign');
|
||||
$table->dropIndex('property_executive_property_id_executive_type_id_unique');
|
||||
});
|
||||
|
||||
Schema::table('property_executive',function (Blueprint $table) {
|
||||
$table->foreign('property_id')->references('id')->on('property');
|
||||
$table->foreign('executive_type_id')->references('id')->on('property_executive_type');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
|
||||
}
|
||||
@@ -0,0 +1,36 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class AddMobile2ToPropertyContact extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::table('property_contact', function (Blueprint $table) {
|
||||
$table->string('mobile2_code',10)->after('mobile')->nullable();
|
||||
$table->string('mobile2',50)->after('mobile2_code')->nullable();
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::table('property_contact', function (Blueprint $table) {
|
||||
$table->dropColumn('mobile2_code');
|
||||
$table->dropColumn('mobile2');
|
||||
|
||||
});
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,32 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class AddSocialMediaAddressesToPropertyContact extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::table('property_contact', function (Blueprint $table) {
|
||||
$table->string('social_media_addresses',512)->after('web')->nullable();
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::table('property_contact', function (Blueprint $table) {
|
||||
$table->dropColumn('social_media_addresses');
|
||||
});
|
||||
}
|
||||
}
|
||||
236
database/migrations/2020_05_18_154634_create_offer_table.php
Normal file
236
database/migrations/2020_05_18_154634_create_offer_table.php
Normal file
@@ -0,0 +1,236 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreateOfferTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('offer', function (Blueprint $table) {
|
||||
$table->bigIncrements('id');
|
||||
$table->unsignedInteger('property_id');
|
||||
$table->string('title',200);
|
||||
$table->mediumText('description')->nullable();
|
||||
$table->date('expire_date');
|
||||
$table->string('language',2);
|
||||
$table->string('currency',3);
|
||||
$table->double('total',10,2)->nullable();
|
||||
$table->integer('payment_type_id')->nullable(); // TODO İlişki Kurulmadı
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::table('offer', function (Blueprint $table) {
|
||||
$table->foreign('property_id')->references('id')->on('property');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
});
|
||||
|
||||
|
||||
|
||||
Schema::create('offer_accommodation_mapping', function (Blueprint $table) {
|
||||
$table->bigIncrements('id');
|
||||
$table->unsignedBigInteger('offer_id');
|
||||
$table->unsignedInteger('property_accommodation_id');
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->dateTime('created_at');
|
||||
$table->dateTime('updated_at');
|
||||
});
|
||||
|
||||
Schema::table('offer_accommodation_mapping', function (Blueprint $table) {
|
||||
$table->foreign('offer_id')->references('id')->on('offer');
|
||||
$table->foreign('property_accommodation_id')->references('id')->on('property_fact');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
});
|
||||
|
||||
Schema::create('offer_cancellation_policy', function (Blueprint $table) {
|
||||
$table->bigIncrements('id');
|
||||
$table->unsignedBigInteger('offer_id');
|
||||
$table->date('start_date');
|
||||
$table->date('end_date');
|
||||
$table->integer('days_before');
|
||||
$table->string('type',3);
|
||||
$table->double('value',10,2);
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::table('offer_cancellation_policy', function (Blueprint $table) {
|
||||
$table->foreign('offer_id')->references('id')->on('offer');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
});
|
||||
|
||||
Schema::create('offer_contact_mapping', function (Blueprint $table) {
|
||||
$table->bigIncrements('id');
|
||||
$table->unsignedBigInteger('offer_id');
|
||||
$table->unsignedInteger('property_executive_id');
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::table('offer_contact_mapping', function (Blueprint $table) {
|
||||
$table->foreign('offer_id')->references('id')->on('offer');
|
||||
$table->foreign('property_executive_id')->references('id')->on('property_executive');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
});
|
||||
|
||||
Schema::create('offer_fact_mapping', function (Blueprint $table) {
|
||||
$table->bigIncrements('id');
|
||||
$table->unsignedBigInteger('offer_id');
|
||||
$table->unsignedInteger('category_id');
|
||||
$table->unsignedInteger('property_fact_parent_id');
|
||||
$table->unsignedInteger('property_fact_id');
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::table('offer_fact_mapping', function (Blueprint $table) {
|
||||
$table->foreign('offer_id')->references('id')->on('offer');
|
||||
$table->foreign('category_id')->references('id')->on('property_fact');
|
||||
$table->foreign('property_fact_parent_id')->references('parent_id')->on('property_fact');
|
||||
$table->foreign('property_fact_id')->references('id')->on('property_fact');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
});
|
||||
|
||||
Schema::create('offer_important_notes', function (Blueprint $table) {
|
||||
$table->bigIncrements('id');
|
||||
$table->unsignedBigInteger('offer_id');
|
||||
$table->mediumText('note')->nullable();
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::table('offer_important_notes', function (Blueprint $table) {
|
||||
$table->foreign('offer_id')->references('id')->on('offer');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
});
|
||||
|
||||
Schema::create('offer_payment_type', function (Blueprint $table) {
|
||||
$table->bigIncrements('id');
|
||||
$table->string('name',200);
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::table('offer_payment_type', function (Blueprint $table) {
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
});
|
||||
|
||||
Schema::create('offer_photo_mapping', function (Blueprint $table) {
|
||||
$table->bigIncrements('id');
|
||||
$table->unsignedBigInteger('offer_id');
|
||||
$table->unsignedInteger('property_photo_id');
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::table('offer_photo_mapping', function (Blueprint $table) {
|
||||
$table->foreign('offer_id')->references('id')->on('offer');
|
||||
$table->foreign('property_photo_id')->references('id')->on('property_photo');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
});
|
||||
|
||||
Schema::create('offer_price', function (Blueprint $table) {
|
||||
$table->bigIncrements('id');
|
||||
$table->unsignedBigInteger('offer_id');
|
||||
$table->date('date');
|
||||
$table->unsignedBigInteger('property_room_id');
|
||||
$table->unsignedInteger('property_accommodation_id');
|
||||
$table->unsignedInteger('number_of_rooms');
|
||||
$table->string('currency',3);
|
||||
$table->double('amount',10,2);
|
||||
$table->double('total_amount',10,2);
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::table('offer_price', function (Blueprint $table) {
|
||||
$table->foreign('offer_id')->references('id')->on('offer');
|
||||
$table->foreign('property_room_id')->references('id')->on('property_room');
|
||||
$table->foreign('property_accommodation_id')->references('id')->on('property_fact');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
});
|
||||
|
||||
Schema::create('offer_room_mapping', function (Blueprint $table) {
|
||||
$table->bigIncrements('id');
|
||||
$table->unsignedBigInteger('offer_id');
|
||||
$table->unsignedBigInteger('property_room_id');
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::table('offer_room_mapping', function (Blueprint $table) {
|
||||
$table->foreign('offer_id')->references('id')->on('offer');
|
||||
$table->foreign('property_room_id')->references('id')->on('property_room');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
});
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
|
||||
Schema::dropIfExists('offer_room_mapping');
|
||||
Schema::dropIfExists('offer_price');
|
||||
Schema::dropIfExists('offer_photo_mapping');
|
||||
Schema::dropIfExists('offer_payment_type');
|
||||
Schema::dropIfExists('offer_important_notes');
|
||||
Schema::dropIfExists('offer_fact_mapping');
|
||||
Schema::dropIfExists('offer_contact_mapping');
|
||||
Schema::dropIfExists('offer_cancellation_policy');
|
||||
Schema::dropIfExists('offer_accommodation_mapping');
|
||||
Schema::dropIfExists('offer');
|
||||
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,43 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePropertyRoomFactMappingTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('property_room_fact_mapping', function (Blueprint $table) {
|
||||
$table->bigIncrements('id');
|
||||
$table->integer('property_id')->unsigned();
|
||||
$table->bigInteger('room_id')->unsigned();
|
||||
$table->integer('fact_id')->unsigned();
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
|
||||
|
||||
$table->foreign('property_id')->references('id')->on('property');
|
||||
$table->foreign('room_id')->references('id')->on('property_room');
|
||||
$table->foreign('fact_id')->references('id')->on('property_fact');
|
||||
$table->unique(['property_id', 'fact_id','room_id'],'pfr_unique');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('property_room_fact_mapping');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,48 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePropertyRoomPhotoMappingTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
|
||||
DB::connection()->statement("ALTER TABLE `offer_photo_mapping`DROP FOREIGN KEY `offer_photo_mapping_property_photo_id_foreign`;");
|
||||
DB::connection()->statement("ALTER TABLE `property_photo` MODIFY COLUMN `id` bigint(20) UNSIGNED NOT NULL AUTO_INCREMENT FIRST");
|
||||
DB::connection()->statement("ALTER TABLE `offer_photo_mapping` MODIFY COLUMN `property_photo_id` bigint(20) UNSIGNED NOT NULL");
|
||||
DB::connection()->statement("ALTER TABLE `offer_photo_mapping` ADD CONSTRAINT `offer_photo_mapping_property_photo_id_foreign` FOREIGN KEY (`property_photo_id`) REFERENCES `property_photo` (`id`) ON DELETE RESTRICT ON UPDATE RESTRICT");
|
||||
|
||||
Schema::create('property_room_photo_mapping', function (Blueprint $table) {
|
||||
$table->bigIncrements('id');
|
||||
$table->integer('property_id')->unsigned();
|
||||
$table->bigInteger('room_id')->unsigned();
|
||||
$table->bigInteger('photo_id')->unsigned();
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
|
||||
$table->foreign('property_id')->references('id')->on('property');
|
||||
$table->foreign('room_id')->references('id')->on('property_room');
|
||||
$table->foreign('photo_id')->references('id')->on('property_photo');
|
||||
$table->unique(['property_id', 'photo_id', 'room_id'],'ppr_unique');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('property_room_photo_mapping');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,48 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePropertyBrandTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('property_brand', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->integer('property_id')->unsigned();
|
||||
$table->string('title', 250);
|
||||
$table->string('color_code_1', 50);
|
||||
$table->string('color_code_2', 50);
|
||||
$table->string('color_code_3', 50);
|
||||
$table->string('logo_path');
|
||||
$table->string('logo_name', 200);
|
||||
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
|
||||
$table->foreign('property_id')->references('id')->on('property');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
$table->unique(['property_id'],'property_unique');
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('property_brand');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,44 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class ChangeOfferAccommodationMappingDateFormat extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::drop('offer_accommodation_mapping');
|
||||
Schema::create('offer_accommodation_mapping', function (Blueprint $table) {
|
||||
$table->bigIncrements('id');
|
||||
$table->unsignedBigInteger('offer_id');
|
||||
$table->unsignedInteger('property_accommodation_id');
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
Schema::table('offer_accommodation_mapping', function (Blueprint $table) {
|
||||
$table->foreign('offer_id')->references('id')->on('offer');
|
||||
$table->foreign('property_accommodation_id')->references('id')->on('property_fact');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
//
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,23 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class AddColumnOfferTableOfferCode extends Migration
|
||||
{
|
||||
public function up()
|
||||
{
|
||||
Schema::table('offer', function (Blueprint $table) {
|
||||
$table->string('offer_code',50)->unique()->nullable();
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
public function down()
|
||||
{
|
||||
Schema::table('offer', function (Blueprint $table) {
|
||||
$table->dropColumn('offer_code');
|
||||
});
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,24 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class AddColumnOfferTableAcceptStatusColumn extends Migration
|
||||
{
|
||||
public function up()
|
||||
{
|
||||
Schema::table('offer', function (Blueprint $table) {
|
||||
$table->tinyInteger('accept_status')->after('status')->default(0)->comment(' 0 pending, 1 accepted, 2 canceled');
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
public function down()
|
||||
{
|
||||
Schema::table('offer', function (Blueprint $table) {
|
||||
$table->dropColumn('accept_status');
|
||||
});
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,34 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class AddIsCoverPhotoToOfferPhotoMapping extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::table('offer_photo_mapping', function (Blueprint $table) {
|
||||
$table->tinyInteger('is_cover')->after('property_photo_id')->default(0)->comment(' 0 false, 1 true (use for cover photo)');
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::table('offer_photo_mapping', function (Blueprint $table) {
|
||||
$table->dropColumn('is_cover');
|
||||
|
||||
});
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,31 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\DB;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class ChangeOfferTableStatusAndAcceptStatusFields extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
DB::statement("ALTER TABLE offer MODIFY COLUMN accept_status tinyint(1) NOT NULL DEFAULT '2' COMMENT '0 canceled, 1 accepted, 2 pending' ");
|
||||
|
||||
DB::statement("ALTER TABLE offer MODIFY COLUMN status tinyint(1) NOT NULL DEFAULT '1' AFTER accept_status");
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,30 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class ChangePropertyTablePropertyTypeIdNameOfficialNameFields extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
DB::statement("ALTER TABLE property MODIFY COLUMN property_type_id int(10) unsigned NOT NULL ");
|
||||
DB::statement("ALTER TABLE property MODIFY COLUMN official_name varchar(255) NOT NULL ");
|
||||
DB::statement("ALTER TABLE property MODIFY COLUMN name varchar(255) NOT NULL ");
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,76 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\DB;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class UpdatePropertyFactTableIcons extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
DB::table('property_fact')->where('id',1)->update(['icon' => '']); // General Amenities
|
||||
DB::table('property_fact')->where('id',257)->update(['icon' => 'fas fa-hot-tub']); // Spa Wellness
|
||||
DB::table('property_fact')->where('id',2)->update(['icon' => '']); // Payment Type
|
||||
DB::table('property_fact')->where('id',258)->update(['icon' => 'fas fa-spa']); // Spa, Wellness & Care
|
||||
DB::table('property_fact')->where('id',9)->update(['icon' => '']); // Accommodation Type
|
||||
DB::table('property_fact')->where('id',10)->update(['icon' => 'fas fa-hotel']); // All inclusive
|
||||
DB::table('property_fact')->where('id',16)->update(['icon' => '']); // Accommodation Services
|
||||
DB::table('property_fact')->where('id',17)->update(['icon' => 'fas fa-concierge-bell']); // Reception
|
||||
DB::table('property_fact')->where('id',26)->update(['icon' => 'fas fa-tv']); // Internet and TV
|
||||
DB::table('property_fact')->where('id',27)->update(['icon' => 'fas fa-wifi']); // Wireless Internet
|
||||
DB::table('property_fact')->where('id',30)->update(['icon' => '']); // Working Area
|
||||
DB::table('property_fact')->where('id',31)->update(['icon' => 'fas fa-briefcase']); // Business Center
|
||||
DB::table('property_fact')->where('id',292)->update(['icon' => '']); // Room Amenities
|
||||
DB::table('property_fact')->where('id',37)->update(['icon' => 'fas fa-shuttle-van']); // Transportation Services
|
||||
DB::table('property_fact')->where('id',293)->update(['icon' => '']); // Common Amenities of Rooms
|
||||
DB::table('property_fact')->where('id',38)->update(['icon' => 'fas fa-car']); // Rent a car
|
||||
DB::table('property_fact')->where('id',44)->update(['icon' => '']); // Facility Amenities
|
||||
DB::table('property_fact')->where('id',45)->update(['icon' => '']); // Activities
|
||||
DB::table('property_fact')->where('id',114)->update(['icon' => '']); // Entertainment on Facility
|
||||
DB::table('property_fact')->where('id',115)->update(['icon' => 'fas fa-sun']); // Outdoor Activities
|
||||
DB::table('property_fact')->where('id',142)->update(['icon' => 'fas fa-swimmer']); // Pool
|
||||
DB::table('property_fact')->where('id',143)->update(['icon' => 'fas fa-swimming-pool']); // Aqua Park
|
||||
DB::table('property_fact')->where('id',154)->update(['icon' => 'fas fa-utensils']); // Food and Beverage, Restaurant
|
||||
DB::table('property_fact')->where('id',182)->update(['icon' => '']); // Public Areas and Facilitiesa
|
||||
DB::table('property_fact')->where('id',183)->update(['icon' => 'fas fa-arrows-alt-v']); // Elevator
|
||||
DB::table('property_fact')->where('id',222)->update(['icon' => 'fas fa-wheelchair']); // Children and Disabled
|
||||
DB::table('property_fact')->where('id',223)->update(['icon' => 'fas fa-baby']); // Baby and Child
|
||||
|
||||
DB::table('property_fact')->where('id',27)->update(['icon' => 'fas fa-wifi']);
|
||||
DB::table('property_fact')->where('id',64)->update(['icon' => 'fas fa-bullseye']);
|
||||
DB::table('property_fact')->where('id',66)->update(['icon' => 'fas fa-golf-ball']);
|
||||
DB::table('property_fact')->where('id',65)->update(['icon' => 'fas fa-ship']);
|
||||
DB::table('property_fact')->where('id',158)->update(['icon' => 'fas fa-glass-martini']);
|
||||
DB::table('property_fact')->where('id',156)->update(['icon' => 'fas fa-beer']);
|
||||
DB::table('property_fact')->where('id',166)->update(['icon' => 'fas fa-wine-bottle']);
|
||||
DB::table('property_fact')->where('id',160)->update(['icon' => 'fas fa-glass-whiskey']);
|
||||
DB::table('property_fact')->where('id',162)->update(['icon' => 'fas fa-cocktail']);
|
||||
DB::table('property_fact')->where('id',148)->update(['icon' => 'fas fa-umbrella-beach']);
|
||||
DB::table('property_fact')->where('id',226)->update(['icon' => 'fas fa-child']);
|
||||
DB::table('property_fact')->where('id',227)->update(['icon' => 'fas fa-swimming-pool']);
|
||||
DB::table('property_fact')->where('id',303)->update(['icon' => 'fas fa-border-none']);
|
||||
DB::table('property_fact')->where('id',320)->update(['icon' => 'fas fa-washer']);
|
||||
DB::table('property_fact')->where('id',313)->update(['icon' => 'fas fa-tshirt']);
|
||||
DB::table('property_fact')->where('id',346)->update(['icon' => 'fas fa-border-all']);
|
||||
DB::table('property_fact')->where('id',335)->update(['icon' => 'fas fa-bolt']);
|
||||
DB::table('property_fact')->where('id',372)->update(['icon' => 'fas fa-swimming-pool']);
|
||||
DB::table('property_fact')->where('id',186)->update(['name' => 'Coffee / Tea Maker']);
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
//
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,34 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class DropColumnFromOfferCancellationPolicy extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::table('offer_cancellation_policy', function (Blueprint $table) {
|
||||
$table->dropColumn('start_date');
|
||||
$table->dropColumn('end_date');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::table('offer_cancellation_policy', function (Blueprint $table) {
|
||||
$table->date('start_date')->default('2020-01-01');
|
||||
$table->date('end_date')->default('2020-01-01');;
|
||||
});
|
||||
}
|
||||
}
|
||||
46
database/migrations/2020_06_16_171417_update_fact_order.php
Normal file
46
database/migrations/2020_06_16_171417_update_fact_order.php
Normal file
@@ -0,0 +1,46 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class UpdateFactOrder extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
|
||||
// amenities sort update
|
||||
DB::connection()->statement("UPDATE property_fact SET order_number = 1 WHERE id = 9");
|
||||
DB::connection()->statement("UPDATE property_fact SET order_number = 2 WHERE id = 16");
|
||||
DB::connection()->statement("UPDATE property_fact SET order_number = 3 WHERE id = 26");
|
||||
DB::connection()->statement("UPDATE property_fact SET order_number = 4 WHERE id = 30 ");
|
||||
DB::connection()->statement("UPDATE property_fact SET order_number = 5 WHERE id = 37 ");
|
||||
DB::connection()->statement("UPDATE property_fact SET order_number = 6 WHERE id = 243");
|
||||
DB::connection()->statement("UPDATE property_fact SET order_number = 7 WHERE id = 2 ");
|
||||
|
||||
// facility
|
||||
DB::connection()->statement("UPDATE property_fact SET order_number = 1 WHERE id = 45 ");
|
||||
DB::connection()->statement("UPDATE property_fact SET order_number = 2 WHERE id = 154 ");
|
||||
DB::connection()->statement("UPDATE property_fact SET order_number = 3 WHERE id = 114 ");
|
||||
DB::connection()->statement("UPDATE property_fact SET order_number = 4 WHERE id = 142");
|
||||
DB::connection()->statement("UPDATE property_fact SET order_number = 5 WHERE id = 257 ");
|
||||
DB::connection()->statement("UPDATE property_fact SET order_number = 6 WHERE id = 182 ");
|
||||
DB::connection()->statement("UPDATE property_fact SET order_number = 7 WHERE id = 223");
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
//
|
||||
}
|
||||
}
|
||||
46
database/migrations/2020_06_17_145049_update_fact_parent.php
Normal file
46
database/migrations/2020_06_17_145049_update_fact_parent.php
Normal file
@@ -0,0 +1,46 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class UpdateFactParent extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
DB::connection()->statement("UPDATE property_fact SET parent_id = 44 WHERE id = 223");
|
||||
DB::connection()->statement("UPDATE property_fact SET parent_id = 1 WHERE id = 243");
|
||||
DB::connection()->statement("UPDATE property_fact SET type = 0 WHERE id = 243");
|
||||
DB::connection()->statement("UPDATE property_fact SET parent_id = 44 WHERE id = 257");
|
||||
DB::connection()->statement("DELETE FROM offer_fact_mapping WHERE property_fact_id = 222");
|
||||
DB::connection()->statement("DELETE FROM offer_fact_mapping WHERE property_fact_parent_id = 222");
|
||||
DB::connection()->statement("DELETE FROM offer_fact_mapping WHERE category_id = 222");
|
||||
DB::connection()->statement("DELETE FROM property_fact_attribute_mapping WHERE fact_id = 222");
|
||||
DB::connection()->statement("DELETE FROM property_fact_mapping WHERE fact_id = 222");
|
||||
DB::connection()->statement("DELETE FROM property_room_fact_mapping WHERE fact_id = 222");
|
||||
DB::connection()->statement("DELETE FROM property_fact_locale WHERE fact_id = 222");
|
||||
DB::connection()->statement("DELETE FROM property_fact WHERE id = 222");
|
||||
|
||||
$updateData = <<<EOT
|
||||
{"dashboard_section":{"general":{"title":"General","title_locale":{"tr":"Genel","en":"General"},"icon":"/img/hede.jpeg","description":"Here you can enter general information such as title, type, contact information, address and location of the property.","description_locale":{"en":"Here you can enter general information such as title, type, contact information, address and location of the property.","tr":"Tesisin adı, tipi, iletişim bilgileri, adres ve konumu gibi genel bilgileri buradan girebilirsin"},"total_childs":5,"childs":{"Content.General.Information":{"title":"Information","title_locale":{"en":"Information","tr":"Bilgi"},"profile_vote":5,"component":"Content.General.Information"},"Content.General.FacilityContact":{"title":"Facility Contact","title_locale":{"en":"Facility Contact","tr":"Tesis İletişim"},"profile_vote":5,"component":"Content.General.FacilityContact"},"Content.General.Location":{"title":"Location","title_locale":{"en":"Location","tr":"Yer"},"profile_vote":5,"component":"Content.General.Location"},"Content.General.Contacts":{"title":"Contacts","title_locale":{"en":"Contacts","tr":"İletişim"},"profile_vote":5,"component":"Content.General.Contacts"},"Content.General.Building":{"title":"Building","title_locale":{"en":"Building","tr":"Bina"},"profile_vote":5,"component":"Content.General.Building"}}},"amenities":{"title":"Amenities","title_locale":{"en":"Amenities","tr":"Kolaylıklar"},"icon":"","description":"Otel iç mekan , dış mekan , oda tipleri gibi bir çok içeriği buradan güncellemeye başkayabilirsin.","description_locale":[],"total_childs":7,"childs":{"Content.Amenities.Accommodation":{"title":"Accommodation","title_locale":{"en":"Accommodation","tr":"Konaklama"},"profile_vote":5,"component":"Content.Amenities.Accommodation"},"Content.Amenities.Services":{"title":"Services","title_locale":{"en":"Services","tr":"Hizmetler"},"profile_vote":5,"component":"Content.Amenities.Services"},"Content.Amenities.Internet":{"title":"Internet","title_locale":{"en":"Internet","tr":"Internet"},"profile_vote":5,"component":"Content.Amenities.Internet"},"Content.Amenities.BusinessCentre":{"title":"Business Centre","title_locale":{"en":"Business Centre","tr":"İş Merkezi"},"profile_vote":5,"component":"Content.Amenities.BusinessCentre"},"Content.Amenities.Disabled":{"title":"Disabled","title_locale":{"en":"Disabled","tr":"Engelli"},"profile_vote":5,"component":"Content.Amenities.Disabled"},"Content.Amenities.Transportation":{"title":"Transportation","title_locale":{"en":"Transportation","tr":"Taşımacılık"},"profile_vote":5,"component":"Content.Amenities.Transportation"},"Content.Amenities.Payment":{"title":"Payment","title_locale":{"en":"Payment","tr":"Ödeme"},"profile_vote":5,"component":"Content.Amenities.Payment"}}},"facility":{"title":"Facility","title_locale":{"en":"Facility","tr":"Tesis"},"icon":"","description":"Tesisin ödeme şekli, konaklama tipi, ulaşım hizmetleri, ortak kullanım alanları gibi genel tesis özelliklerini buradan seçebilirsin","description_locale":[],"total_childs":7,"childs":{"Content.Facility.Public":{"title":"Public","title_locale":{"en":"Public","tr":"Halk, Umumi, Kamu"},"profile_vote":5,"component":"Content.Facility.Public"},"Content.Facility.FoodDrink":{"title":"Food & Drink","title_locale":{"en":"Food & Drink","tr":"Yiyecek Içecek"},"profile_vote":5,"component":"Content.Facility.FoodDrink"},"Content.Facility.Pool":{"title":"Pool","title_locale":{"en":"Pool","tr":"Havuz"},"profile_vote":5,"component":"Content.Facility.Pool"},"Content.Facility.SpaWellness":{"title":"Spa, Wellness","title_locale":{"en":"Spa, Wellness","tr":"Spa, Sağlık"},"profile_vote":5,"component":"Content.Facility.SpaWellness"},"Content.Facility.Activities":{"title":"Activities","title_locale":{"en":"Activities","tr":"Aktiviteler"},"profile_vote":5,"component":"Content.Facility.Activities"}}},"room":{"title":"Room","title_locale":{"en":"Room","tr":"Oda"},"icon":"","description":"Enter and edit room and common amenities of rooms details here","description_locale":[],"total_childs":3,"childs":{}}},"vote_text":{"20":{"title":"Very Bad Level","title_locale":{"en":"Very Bad Level","tr":"Çok Kötü Seviye"}},"40":{"title":"Bad Level","title_locale":{"en":"Bad Level","tr":"Kötü Seviye"}},"60":{"title":"Intermediate","title_locale":{"en":"Intermediate","tr":"Orta Seviye"}},"80":{"title":"Good Level","title_locale":{"en":"Good Level","tr":"İyi Seviye"}},"100":{"title":"Very Good Level","title_locale":{"en":"Very Good Level","tr":"Çok İyi Seviye"}}}}
|
||||
EOT;
|
||||
|
||||
DB::table('site_config')->where('id',1)->update(['config_value_json' => $updateData]);
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
//
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,37 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreateCountryTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('country', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->string('name', 100)->unique();
|
||||
$table->string('country_code',5)->unique();
|
||||
$table->string('phone_code',10)->nullable();
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('country');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,36 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class UpdatePropertyFactData extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
DB::connection()->statement("UPDATE property_fact SET parent_id = 44, order_number = 5 WHERE id = 258");
|
||||
DB::connection()->statement("DELETE FROM offer_fact_mapping WHERE property_fact_id = 257");
|
||||
DB::connection()->statement("DELETE FROM offer_fact_mapping WHERE property_fact_parent_id = 257");
|
||||
DB::connection()->statement("DELETE FROM offer_fact_mapping WHERE category_id = 257");
|
||||
DB::connection()->statement("DELETE FROM property_fact_attribute_mapping WHERE fact_id = 257");
|
||||
DB::connection()->statement("DELETE FROM property_fact_mapping WHERE fact_id = 257");
|
||||
DB::connection()->statement("DELETE FROM property_room_fact_mapping WHERE fact_id = 257");
|
||||
DB::connection()->statement("DELETE FROM property_fact_locale WHERE fact_id = 257");
|
||||
DB::connection()->statement("DELETE FROM property_fact WHERE id = 257");
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
//
|
||||
}
|
||||
}
|
||||
272
database/migrations/2020_06_18_132804_country_table_add_data.php
Normal file
272
database/migrations/2020_06_18_132804_country_table_add_data.php
Normal file
@@ -0,0 +1,272 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\DB;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CountryTableAddData extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (1, 'Aruba', 'AW', '297', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (2, 'Afghanistan', 'AF', '93', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (3, 'Angola', 'AO', '244', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (4, 'Anguilla', 'AI', '1264', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (5, 'Ãland Islands', 'AX', '358', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (6, 'Albania', 'AL', '355', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (7, 'Andorra', 'AD', '376', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (8, 'United Arab Emirates', 'AE', '971', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (9, 'Argentina', 'AR', '54', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (10, 'Armenia', 'AM', '374', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (11, 'American Samoa', 'AS', '1684', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (12, 'Antigua and Barbuda', 'AG', '1268', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (13, 'Australia', 'AU', '61', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (14, 'Austria', 'AT', '43', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (15, 'Azerbaijan', 'AZ', '994', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (16, 'Burundi', 'BI', '257', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (17, 'Belgium', 'BE', '32', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (18, 'Benin', 'BJ', '229', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (19, 'Burkina Faso', 'BF', '226', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (20, 'Bangladesh', 'BD', '880', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (21, 'Bulgaria', 'BG', '359', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (22, 'Bahrain', 'BH', '973', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (23, 'Bahamas', 'BS', '1242', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (24, 'Bosnia and Herzegovina', 'BA', '387', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (25, 'Saint Barthélemy', 'BL', '590', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (26, 'Belarus', 'BY', '375', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (27, 'Belize', 'BZ', '501', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (28, 'Bermuda', 'BM', '1441', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (29, 'Bolivia', 'BO', '591', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (30, 'Brazil', 'BR', '55', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (31, 'Barbados', 'BB', '1246', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (32, 'Brunei', 'BN', '673', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (33, 'Bhutan', 'BT', '975', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (34, 'Botswana', 'BW', '267', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (35, 'Central African Republic', 'CF', '236', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (36, 'Canada', 'CA', '1', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (37, 'Cocos (Keeling) Islands', 'CC', '61', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (38, 'Switzerland', 'CH', '41', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (39, 'Chile', 'CL', '56', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (40, 'China', 'CN', '86', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (41, 'Ivory Coast', 'CI', '225', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (42, 'Cameroon', 'CM', '237', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (43, 'DR Congo', 'CD', '243', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (44, 'Republic of the Congo', 'CG', '242', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (45, 'Cook Islands', 'CK', '682', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (46, 'Colombia', 'CO', '57', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (47, 'Comoros', 'KM', '269', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (48, 'Cape Verde', 'CV', '238', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (49, 'Costa Rica', 'CR', '506', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (50, 'Cuba', 'CU', '53', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (51, 'Curaçao', 'CW', '5999', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (52, 'Christmas Island', 'CX', '61', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (53, 'Cayman Islands', 'KY', '1345', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (54, 'Cyprus', 'CY', '357', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (55, 'Czechia', 'CZ', '420', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (56, 'Germany', 'DE', '49', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (57, 'Djibouti', 'DJ', '253', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (58, 'Dominica', 'DM', '1767', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (59, 'Denmark', 'DK', '45', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (60, 'Dominican Republic', 'DO', '1809', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (61, 'Algeria', 'DZ', '213', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (62, 'Ecuador', 'EC', '593', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (63, 'Egypt', 'EG', '20', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (64, 'Eritrea', 'ER', '291', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (65, 'Western Sahara', 'EH', '212', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (66, 'Spain', 'ES', '34', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (67, 'Estonia', 'EE', '372', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (68, 'Ethiopia', 'ET', '251', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (69, 'Finland', 'FI', '358', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (70, 'Fiji', 'FJ', '679', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (71, 'Falkland Islands', 'FK', '500', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (72, 'France', 'FR', '33', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (73, 'Faroe Islands', 'FO', '298', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (74, 'Micronesia', 'FM', '691', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (75, 'Gabon', 'GA', '241', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (76, 'United Kingdom', 'GB', '44', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (77, 'Georgia', 'GE', '995', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (78, 'Guernsey', 'GG', '44', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (79, 'Ghana', 'GH', '233', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (80, 'Gibraltar', 'GI', '350', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (81, 'Guinea', 'GN', '224', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (82, 'Guadeloupe', 'GP', '590', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (83, 'Gambia', 'GM', '220', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (84, 'Guinea-Bissau', 'GW', '245', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (85, 'Equatorial Guinea', 'GQ', '240', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (86, 'Greece', 'GR', '30', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (87, 'Grenada', 'GD', '1473', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (88, 'Greenland', 'GL', '299', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (89, 'Guatemala', 'GT', '502', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (90, 'French Guiana', 'GF', '594', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (91, 'Guam', 'GU', '1671', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (92, 'Guyana', 'GY', '592', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (93, 'Hong Kong', 'HK', '852', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (94, 'Honduras', 'HN', '504', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (95, 'Croatia', 'HR', '385', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (96, 'Haiti', 'HT', '509', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (97, 'Hungary', 'HU', '36', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (98, 'Indonesia', 'ID', '62', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (99, 'Isle of Man', 'IM', '44', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (100, 'India', 'IN', '91', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (101, 'British Indian Ocean Territory', 'IO', '246', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (102, 'Ireland', 'IE', '353', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (103, 'Iran', 'IR', '98', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (104, 'Iraq', 'IQ', '964', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (105, 'Iceland', 'IS', '354', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (106, 'Israel', 'IL', '972', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (107, 'Italy', 'IT', '39', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (108, 'Jamaica', 'JM', '1876', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (109, 'Jersey', 'JE', '44', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (110, 'Jordan', 'JO', '962', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (111, 'Japan', 'JP', '81', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (112, 'Kazakhstan', 'KZ', '77', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (113, 'Kenya', 'KE', '254', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (114, 'Kyrgyzstan', 'KG', '996', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (115, 'Cambodia', 'KH', '855', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (116, 'Kiribati', 'KI', '686', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (117, 'Saint Kitts and Nevis', 'KN', '1869', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (118, 'South Korea', 'KR', '82', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (119, 'Kosovo', 'XK', '383', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (120, 'Kuwait', 'KW', '965', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (121, 'Laos', 'LA', '856', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (122, 'Lebanon', 'LB', '961', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (123, 'Liberia', 'LR', '231', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (124, 'Libya', 'LY', '218', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (125, 'Saint Lucia', 'LC', '1758', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (126, 'Liechtenstein', 'LI', '423', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (127, 'Sri Lanka', 'LK', '94', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (128, 'Lesotho', 'LS', '266', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (129, 'Lithuania', 'LT', '370', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (130, 'Luxembourg', 'LU', '352', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (131, 'Latvia', 'LV', '371', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (132, 'Macau', 'MO', '853', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (133, 'Saint Martin', 'MF', '590', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (134, 'Morocco', 'MA', '212', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (135, 'Monaco', 'MC', '377', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (136, 'Moldova', 'MD', '373', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (137, 'Madagascar', 'MG', '261', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (138, 'Maldives', 'MV', '960', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (139, 'Mexico', 'MX', '52', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (140, 'Marshall Islands', 'MH', '692', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (141, 'Macedonia', 'MK', '389', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (142, 'Mali', 'ML', '223', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (143, 'Malta', 'MT', '356', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (144, 'Myanmar', 'MM', '95', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (145, 'Montenegro', 'ME', '382', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (146, 'Mongolia', 'MN', '976', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (147, 'Northern Mariana Islands', 'MP', '1670', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (148, 'Mozambique', 'MZ', '258', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (149, 'Mauritania', 'MR', '222', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (150, 'Montserrat', 'MS', '1664', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (151, 'Martinique', 'MQ', '596', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (152, 'Mauritius', 'MU', '230', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (153, 'Malawi', 'MW', '265', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (154, 'Malaysia', 'MY', '60', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (155, 'Mayotte', 'YT', '262', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (156, 'Namibia', 'NA', '264', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (157, 'New Caledonia', 'NC', '687', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (158, 'Niger', 'NE', '227', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (159, 'Norfolk Island', 'NF', '672', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (160, 'Nigeria', 'NG', '234', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (161, 'Nicaragua', 'NI', '505', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (162, 'Niue', 'NU', '683', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (163, 'Netherlands', 'NL', '31', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (164, 'Norway', 'NO', '47', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (165, 'Nepal', 'NP', '977', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (166, 'Nauru', 'NR', '674', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (167, 'New Zealand', 'NZ', '64', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (168, 'Oman', 'OM', '968', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (169, 'Pakistan', 'PK', '92', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (170, 'Panama', 'PA', '507', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (171, 'Pitcairn Islands', 'PN', '64', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (172, 'Peru', 'PE', '51', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (173, 'Philippines', 'PH', '63', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (174, 'Palau', 'PW', '680', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (175, 'Papua New Guinea', 'PG', '675', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (176, 'Poland', 'PL', '48', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (177, 'Puerto Rico', 'PR', '1787', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (178, 'North Korea', 'KP', '850', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (179, 'Portugal', 'PT', '351', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (180, 'Paraguay', 'PY', '595', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (181, 'Palestine', 'PS', '970', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (182, 'French Polynesia', 'PF', '689', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (183, 'Qatar', 'QA', '974', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (184, 'Réunion', 'RE', '262', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (185, 'Romania', 'RO', '40', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (186, 'Russia', 'RU', '7', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (187, 'Rwanda', 'RW', '250', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (188, 'Saudi Arabia', 'SA', '966', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (189, 'Sudan', 'SD', '249', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (190, 'Senegal', 'SN', '221', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (191, 'Singapore', 'SG', '65', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (192, 'South Georgia', 'GS', '500', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (193, 'Svalbard and Jan Mayen', 'SJ', '4779', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (194, 'Solomon Islands', 'SB', '677', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (195, 'Sierra Leone', 'SL', '232', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (196, 'El Salvador', 'SV', '503', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (197, 'San Marino', 'SM', '378', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (198, 'Somalia', 'SO', '252', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (199, 'Saint Pierre and Miquelon', 'PM', '508', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (200, 'Serbia', 'RS', '381', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (201, 'South Sudan', 'SS', '211', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (202, 'São Tomé and Príncipe', 'ST', '239', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (203, 'Suriname', 'SR', '597', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (204, 'Slovakia', 'SK', '421', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (205, 'Slovenia', 'SI', '386', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (206, 'Sweden', 'SE', '46', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (207, 'Swaziland', 'SZ', '268', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (208, 'Sint Maarten', 'SX', '1721', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (209, 'Seychelles', 'SC', '248', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (210, 'Syria', 'SY', '963', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (211, 'Turks and Caicos Islands', 'TC', '1649', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (212, 'Chad', 'TD', '235', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (213, 'Togo', 'TG', '228', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (214, 'Thailand', 'TH', '66', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (215, 'Tajikistan', 'TJ', '992', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (216, 'Tokelau', 'TK', '690', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (217, 'Turkmenistan', 'TM', '993', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (218, 'Timor-Leste', 'TL', '670', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (219, 'Tonga', 'TO', '676', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (220, 'Trinidad and Tobago', 'TT', '1868', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (221, 'Tunisia', 'TN', '216', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (222, 'Turkey', 'TR', '90', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (223, 'Tuvalu', 'TV', '688', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (224, 'Taiwan', 'TW', '886', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (225, 'Tanzania', 'TZ', '255', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (226, 'Uganda', 'UG', '256', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (227, 'Ukraine', 'UA', '380', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (228, 'Uruguay', 'UY', '598', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (229, 'United States', 'US', '1', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (230, 'Uzbekistan', 'UZ', '998', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (231, 'Vatican City', 'VA', '379', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (232, 'Saint Vincent and the Grenadines', 'VC', '1784', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (233, 'Venezuela', 'VE', '58', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (234, 'British Virgin Islands', 'VG', '1284', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (235, 'United States Virgin Islands', 'VI', '1340', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (236, 'Vietnam', 'VN', '84', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (237, 'Vanuatu', 'VU', '678', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (238, 'Wallis and Futuna', 'WF', '681', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (239, 'Samoa', 'WS', '685', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (240, 'Yemen', 'YE', '967', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (241, 'South Africa', 'ZA', '27', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (242, 'Zambia', 'ZM', '260', 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `country` VALUES (243, 'Zimbabwe', 'ZW', '263', 1, 1, 1, 1)");
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,60 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class DropColumnCheckinFromPropertyTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::table('property', function (Blueprint $table) {
|
||||
|
||||
|
||||
$table->dropColumn('checkin_time');
|
||||
$table->dropColumn('checkout_time');
|
||||
});
|
||||
|
||||
DB::table('property_additional_info_key')->insert(
|
||||
[
|
||||
[
|
||||
'additional_info_key' => 'checkin_time',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'additional_info_key' => 'checkout_time',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
]
|
||||
]
|
||||
|
||||
);
|
||||
|
||||
DB::connection()->statement("UPDATE property_additional_info_key SET status = 0 WHERE additional_info_key = 'pet' ");
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::table('property', function (Blueprint $table) {
|
||||
$table->string('checkin_time',50)->nullable();
|
||||
$table->string('checkout_time',50)->nullable();
|
||||
});
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,26 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class AddColumnPropertyTableCountryField extends Migration
|
||||
{
|
||||
public function up()
|
||||
{
|
||||
Schema::table('property', function (Blueprint $table) {
|
||||
$table->string('country',5)->after('destination_id')->nullable();
|
||||
|
||||
});
|
||||
|
||||
Schema::table('property', function (Blueprint $table) {
|
||||
$table->foreign('country')->references('country_code')->on('country');
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
public function down()
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,33 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class AddColumnCountryTableStatusField extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::table('country', function (Blueprint $table) {
|
||||
$table->tinyInteger('status')->after('phone_code')->default(1);
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::table('country', function (Blueprint $table) {
|
||||
$table->dropColumn('status');
|
||||
});
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,38 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\DB;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class ChangeColumnsPropertyTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
DB::statement("ALTER TABLE property MODIFY COLUMN name varchar(255) NOT NULL");
|
||||
DB::statement("ALTER TABLE property MODIFY COLUMN destination_id int(10) unsigned DEFAULT NULL");
|
||||
DB::statement("ALTER TABLE property MODIFY COLUMN country varchar(5) DEFAULT NULL");
|
||||
DB::statement("ALTER TABLE property MODIFY COLUMN property_type_id int(10) unsigned DEFAULT NULL");
|
||||
DB::statement("ALTER TABLE property MODIFY COLUMN chain_id int(10) unsigned DEFAULT NULL");
|
||||
DB::statement("ALTER TABLE property MODIFY COLUMN rating double DEFAULT NULL");
|
||||
DB::statement("ALTER TABLE property MODIFY COLUMN official_name varchar(255) DEFAULT NULL");
|
||||
DB::statement("ALTER TABLE property MODIFY COLUMN tax_office varchar(255) DEFAULT NULL");
|
||||
DB::statement("ALTER TABLE property MODIFY COLUMN tax_number varchar(255) DEFAULT NULL");
|
||||
DB::statement("ALTER TABLE property MODIFY COLUMN currency_type varchar(3) DEFAULT NULL");
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
//
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,33 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class AddColumnExtensionFieldPropertyExecutiveTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::table('property_executive', function (Blueprint $table) {
|
||||
$table->string('extension', 10)->after('phone')->nullable();
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::table('property_executive', function (Blueprint $table) {
|
||||
$table->dropColumn('extension');
|
||||
});
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class AddColumnsToUserTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::table('user', function (Blueprint $table) {
|
||||
|
||||
DB::statement("ALTER TABLE `user` CHANGE COLUMN `locale` `language` VARCHAR(2) DEFAULT NULL ");
|
||||
DB::statement("ALTER TABLE `user` MODIFY COLUMN `gender` varchar(2) DEFAULT NULL");
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::table('user', function (Blueprint $table) {
|
||||
|
||||
DB::statement("ALTER TABLE `user` CHANGE COLUMN `language` `locale` VARCHAR(2) DEFAULT NULL");
|
||||
});
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,28 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class DropTableDestinationTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::dropIfExists('destination');
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
//
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,23 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class AddColumnPropertyRoomExcludeOccupancyField extends Migration
|
||||
{
|
||||
public function up()
|
||||
{
|
||||
Schema::table('property_room', function (Blueprint $table) {
|
||||
$table->string('exclude_occupancy', 500)->after('max_child')->nullable();
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
public function down()
|
||||
{
|
||||
Schema::table('property_room', function (Blueprint $table) {
|
||||
$table->dropColumn('exclude_occupancy');
|
||||
});
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,39 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class ChangeColumnsPropertyExecutiveTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
DB::statement("ALTER TABLE property_executive MODIFY COLUMN property_id int(10) unsigned NOT NULL");
|
||||
DB::statement("ALTER TABLE property_executive MODIFY COLUMN executive_type_id int(10) unsigned NOT NULL");
|
||||
DB::statement("ALTER TABLE property_executive MODIFY COLUMN name_surname varchar(200) NOT NULL");
|
||||
DB::statement("ALTER TABLE property_executive MODIFY COLUMN email varchar(100) DEFAULT NULL ");
|
||||
DB::statement("ALTER TABLE property_executive MODIFY COLUMN phone_code varchar(10) DEFAULT NULL ");
|
||||
DB::statement("ALTER TABLE property_executive MODIFY COLUMN phone varchar(50) DEFAULT NULL ");
|
||||
DB::statement("ALTER TABLE property_executive MODIFY COLUMN extension varchar(10) DEFAULT NULL ");
|
||||
DB::statement("ALTER TABLE property_executive MODIFY COLUMN mobile_code varchar(10) DEFAULT NULL ");
|
||||
DB::statement("ALTER TABLE property_executive MODIFY COLUMN mobile varchar(50) DEFAULT NULL ");
|
||||
DB::statement("ALTER TABLE property_executive MODIFY COLUMN fax_code varchar(10) DEFAULT NULL ");
|
||||
DB::statement("ALTER TABLE property_executive MODIFY COLUMN fax varchar(50) DEFAULT NULL ");
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,34 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class ChangeColumnsPropertyBrandTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
DB::statement("ALTER TABLE property_brand MODIFY COLUMN title VARCHAR(250) DEFAULT NULL ");
|
||||
DB::statement("ALTER TABLE property_brand MODIFY COLUMN color_code_1 VARCHAR(50) DEFAULT NULL ");
|
||||
DB::statement("ALTER TABLE property_brand MODIFY COLUMN color_code_2 VARCHAR(50) DEFAULT NULL ");
|
||||
DB::statement("ALTER TABLE property_brand MODIFY COLUMN color_code_3 VARCHAR(50) DEFAULT NULL ");
|
||||
DB::statement("ALTER TABLE property_brand MODIFY COLUMN logo_path VARCHAR(255) DEFAULT NULL ");
|
||||
DB::statement("ALTER TABLE property_brand MODIFY COLUMN logo_name VARCHAR(200) DEFAULT NULL ");
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
//
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,309 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class ChangeTableLanguageTableCreateValues extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::table('language', function (Blueprint $table) {
|
||||
$table->tinyInteger('is_application')->after('status')->default(0);
|
||||
$table->tinyInteger('is_published')->after('is_application')->default(0);
|
||||
});
|
||||
|
||||
DB::statement("ALTER TABLE language MODIFY COLUMN code VARCHAR(10) NOT NULL");
|
||||
|
||||
DB::statement('SET FOREIGN_KEY_CHECKS=0;');
|
||||
DB::table('language')->truncate();
|
||||
DB::statement('SET FOREIGN_KEY_CHECKS=1;');
|
||||
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (1, 'af', 'Afrikaans', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (2, 'af_ZA', 'Afrikaans (South Africa)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (3, 'ar', 'Arabic', 1, 1, 1, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (4, 'ar_AE', 'Arabic (U.A.E.)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (5, 'ar_BH', 'Arabic (Bahrain)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (6, 'ar_DZ', 'Arabic (Algeria)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (7, 'ar_EG', 'Arabic (Egypt)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (8, 'ar_IQ', 'Arabic (Iraq)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (9, 'ar_JO', 'Arabic (Jordan)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (10, 'ar_KW', 'Arabic (Kuwait)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (11, 'ar_LB', 'Arabic (Lebanon)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (12, 'ar_LY', 'Arabic (Libya)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (13, 'ar_MA', 'Arabic (Morocco)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (14, 'ar_OM', 'Arabic (Oman)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (15, 'ar_QA', 'Arabic (Qatar)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (16, 'ar_SA', 'Arabic (Saudi Arabia)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (17, 'ar_SY', 'Arabic (Syria)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (18, 'ar_TN', 'Arabic (Tunisia)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (19, 'ar_YE', 'Arabic (Yemen)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (20, 'az', 'Azeri (Latin)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (21, 'az_AZ', 'Azeri (Cyrillic) (Azerbaijan)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (22, 'be', 'Belarusian', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (23, 'be_BY', 'Belarusian (Belarus)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (24, 'bg', 'Bulgarian', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (25, 'bg_BG', 'Bulgarian (Bulgaria)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (26, 'bs_BA', 'Bosnian (Bosnia and Herzegovina)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (27, 'ca', 'Catalan', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (28, 'ca_ES', 'Catalan (Spain)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (29, 'cs', 'Czech', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (30, 'cs_CZ', 'Czech (Czech Republic)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (31, 'cy', 'Welsh', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (32, 'cy_GB', 'Welsh (United Kingdom)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (33, 'da', 'Danish', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (34, 'da_DK', 'Danish (Denmark)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (35, 'de', 'German', 1, 1, 1, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (36, 'de_AT', 'German (Austria)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (37, 'de_CH', 'German (Switzerland)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (38, 'de_DE', 'German (Germany)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (39, 'de_LI', 'German (Liechtenstein)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (40, 'de_LU', 'German (Luxembourg)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (41, 'dv', 'Divehi', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (42, 'dv_MV', 'Divehi (Maldives)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (43, 'el', 'Greek', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (44, 'el_GR', 'Greek (Greece)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (45, 'en', 'English', 1, 1, 1, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (46, 'en_AU', 'English (Australia)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (47, 'en_BZ', 'English (Belize)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (48, 'en_CA', 'English (Canada)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (49, 'en_CB', 'English (Caribbean)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (50, 'en_GB', 'English (United Kingdom)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (51, 'en_IE', 'English (Ireland)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (52, 'en_JM', 'English (Jamaica)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (53, 'en_NZ', 'English (New Zealand)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (54, 'en_PH', 'English (Republic of the Philippines)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (55, 'en_TT', 'English (Trinidad and Tobago)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (56, 'en_US', 'English (United States)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (57, 'en_ZA', 'English (South Africa)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (58, 'en_ZW', 'English (Zimbabwe)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (59, 'eo', 'Esperanto', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (60, 'es', 'Spanish', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (61, 'es_AR', 'Spanish (Argentina)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (62, 'es_BO', 'Spanish (Bolivia)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (63, 'es_CL', 'Spanish (Chile)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (64, 'es_CO', 'Spanish (Colombia)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (65, 'es_CR', 'Spanish (Costa Rica)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (66, 'es_DO', 'Spanish (Dominican Republic)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (67, 'es_EC', 'Spanish (Ecuador)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (68, 'es_ES', 'Spanish (Spain)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (69, 'es_GT', 'Spanish (Guatemala)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (70, 'es_HN', 'Spanish (Honduras)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (71, 'es_MX', 'Spanish (Mexico)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (72, 'es_NI', 'Spanish (Nicaragua)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (73, 'es_PA', 'Spanish (Panama)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (74, 'es_PE', 'Spanish (Peru)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (75, 'es_PR', 'Spanish (Puerto Rico)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (76, 'es_PY', 'Spanish (Paraguay)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (77, 'es_SV', 'Spanish (El Salvador)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (78, 'es_UY', 'Spanish (Uruguay)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (79, 'es_VE', 'Spanish (Venezuela)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (80, 'et', 'Estonian', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (81, 'et_EE', 'Estonian (Estonia)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (82, 'eu', 'Basque', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (83, 'eu_ES', 'Basque (Spain)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (84, 'fa', 'Farsi', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (85, 'fa_IR', 'Farsi (Iran)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (86, 'fi', 'Finnish', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (87, 'fi_FI', 'Finnish (Finland)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (88, 'fo', 'Faroese', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (89, 'fo_FO', 'Faroese (Faroe Islands)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (90, 'fr', 'French', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (91, 'fr_BE', 'French (Belgium)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (92, 'fr_CA', 'French (Canada)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (93, 'fr_CH', 'French (Switzerland)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (94, 'fr_FR', 'French (France)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (95, 'fr_LU', 'French (Luxembourg)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (96, 'fr_MC', 'French (Principality of Monaco)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (97, 'gl', 'Galician', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (98, 'gl_ES', 'Galician (Spain)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (99, 'gu', 'Gujarati', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (100, 'gu_IN', 'Gujarati (India)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (101, 'he', 'Hebrew', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (102, 'he_IL', 'Hebrew (Israel)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (103, 'hi', 'Hindi', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (104, 'hi_IN', 'Hindi (India)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (105, 'hr', 'Croatian', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (106, 'hr_BA', 'Croatian (Bosnia and Herzegovina)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (107, 'hr_HR', 'Croatian (Croatia)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (108, 'hu', 'Hungarian', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (109, 'hu_HU', 'Hungarian (Hungary)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (110, 'hy', 'Armenian', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (111, 'hy_AM', 'Armenian (Armenia)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (112, 'id', 'Indonesian', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (113, 'id_ID', 'Indonesian (Indonesia)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (114, 'is', 'Icelandic', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (115, 'is_IS', 'Icelandic (Iceland)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (116, 'it', 'Italian', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (117, 'it_CH', 'Italian (Switzerland)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (118, 'it_IT', 'Italian (Italy)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (119, 'ja', 'Japanese', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (120, 'ja_JP', 'Japanese (Japan)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (121, 'ka', 'Georgian', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (122, 'ka_GE', 'Georgian (Georgia)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (123, 'kk', 'Kazakh', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (124, 'kk_KZ', 'Kazakh (Kazakhstan)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (125, 'kn', 'Kannada', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (126, 'kn_IN', 'Kannada (India)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (127, 'ko', 'Korean', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (128, 'ko_KR', 'Korean (Korea)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (129, 'kok', 'Konkani', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (130, 'kok_IN', 'Konkani (India)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (131, 'ky', 'Kyrgyz', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (132, 'ky_KG', 'Kyrgyz (Kyrgyzstan)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (133, 'lt', 'Lithuanian', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (134, 'lt_LT', 'Lithuanian (Lithuania)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (135, 'lv', 'Latvian', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (136, 'lv_LV', 'Latvian (Latvia)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (137, 'mi', 'Maori', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (138, 'mi_NZ', 'Maori (New Zealand)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (139, 'mk', 'FYRO Macedonian', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (140, 'mk_MK', 'FYRO Macedonian (Former Yugoslav Republic of ', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (141, 'mn', 'Mongolian', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (142, 'mn_MN', 'Mongolian (Mongolia)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (143, 'mr', 'Marathi', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (144, 'mr_IN', 'Marathi (India)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (145, 'ms', 'Malay', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (146, 'ms_BN', 'Malay (Brunei Darussalam)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (147, 'ms_MY', 'Malay (Malaysia)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (148, 'mt', 'Maltese', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (149, 'mt_MT', 'Maltese (Malta)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (150, 'nb', 'Norwegian (Bokm?l)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (151, 'nb_NO', 'Norwegian (Bokm?l) (Norway)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (152, 'nl', 'Dutch', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (153, 'nl_BE', 'Dutch (Belgium)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (154, 'nl_NL', 'Dutch (Netherlands)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (155, 'nn_NO', 'Norwegian (Nynorsk) (Norway)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (156, 'ns', 'Northern Sotho', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (157, 'ns_ZA', 'Northern Sotho (South Africa)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (158, 'pa', 'Punjabi', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (159, 'pa_IN', 'Punjabi (India)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (160, 'pl', 'Polish', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (161, 'pl_PL', 'Polish (Poland)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (162, 'ps', 'Pashto', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (163, 'ps_AR', 'Pashto (Afghanistan)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (164, 'pt', 'Portuguese', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (165, 'pt_BR', 'Portuguese (Brazil)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (166, 'pt_PT', 'Portuguese (Portugal)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (167, 'qu', 'Quechua', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (168, 'qu_BO', 'Quechua (Bolivia)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (169, 'qu_EC', 'Quechua (Ecuador)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (170, 'qu_PE', 'Quechua (Peru)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (171, 'ro', 'Romanian', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (172, 'ro_RO', 'Romanian (Romania)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (173, 'ru', 'Russian', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (174, 'ru_RU', 'Russian (Russia)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (175, 'sa', 'Sanskrit', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (176, 'sa_IN', 'Sanskrit (India)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (177, 'se', 'Sami (Northern)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (178, 'se_FI', 'Sami (Northern) (Finland)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (179, 'se_NO', 'Sami (Northern) (Norway)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (180, 'se_SE', 'Sami (Northern) (Sweden)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (181, 'sk', 'Slovak', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (182, 'sk_SK', 'Slovak (Slovakia)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (183, 'sl', 'Slovenian', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (184, 'sl_SI', 'Slovenian (Slovenia)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (185, 'sq', 'Albanian', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (186, 'sq_AL', 'Albanian (Albania)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (187, 'sr_BA', 'Serbian (Cyrillic) (Bosnia and Herzegovina)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (188, 'sr_SP', 'Serbian (Cyrillic) (Serbia and Montenegro)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (189, 'sv', 'Swedish', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (190, 'sv_FI', 'Swedish (Finland)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (191, 'sv_SE', 'Swedish (Sweden)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (192, 'sw', 'Swahili', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (193, 'sw_KE', 'Swahili (Kenya)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (194, 'syr', 'Syriac', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (195, 'syr_SY', 'Syriac (Syria)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (196, 'ta', 'Tamil', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (197, 'ta_IN', 'Tamil (India)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (198, 'te', 'Telugu', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (199, 'te_IN', 'Telugu (India)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (200, 'th', 'Thai', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (201, 'th_TH', 'Thai (Thailand)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (202, 'tl', 'Tagalog', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (203, 'tl_PH', 'Tagalog (Philippines)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (204, 'tn', 'Tswana', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (205, 'tn_ZA', 'Tswana (South Africa)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (206, 'tr', 'Turkish', 1, 1, 1, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (207, 'tr_TR', 'Turkish (Turkey)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (208, 'ts', 'Tsonga', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (209, 'tt', 'Tatar', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (210, 'tt_RU', 'Tatar (Russia)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (211, 'uk', 'Ukrainian', 1, 1, 1, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (212, 'uk_UA', 'Ukrainian (Ukraine)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (213, 'ur', 'Urdu', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (214, 'ur_PK', 'Urdu (Islamic Republic of Pakistan)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (215, 'uz', 'Uzbek (Latin)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (216, 'uz_UZ', 'Uzbek (Cyrillic) (Uzbekistan)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (217, 'vi', 'Vietnamese', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (218, 'vi_VN', 'Vietnamese (Viet Nam)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (219, 'xh', 'Xhosa', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (220, 'xh_ZA', 'Xhosa (South Africa)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (221, 'zh', 'Chinese', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (222, 'zh_CN', 'Chinese (S)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (223, 'zh_HK', 'Chinese (Hong Kong)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (224, 'zh_MO', 'Chinese (Macau)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (225, 'zh_SG', 'Chinese (Singapore)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (226, 'zh_TW', 'Chinese (T)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (227, 'zu', 'Zulu', 1, 0, 0, 1, 1, 1, 1)");
|
||||
DB::connection()->statement("INSERT INTO `language` VALUES (228, 'zu_ZA', 'Zulu (South Africa)', 1, 0, 0, 1, 1, 1, 1)");
|
||||
|
||||
Schema::create('language_base', function (Blueprint $table) {
|
||||
$table->bigIncrements('id');
|
||||
$table->string('key',100)->unique();
|
||||
$table->string('hashed',45)->nullable();
|
||||
$table->string('code',10);
|
||||
$table->mediumText('text');
|
||||
$table->mediumText('description')->nullable();
|
||||
$table->tinyInteger('status')->default(0);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::table('language_base', function (Blueprint $table) {
|
||||
$table->foreign('code')->references('code')->on('language');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
});
|
||||
|
||||
|
||||
Schema::create('language_translate', function (Blueprint $table) {
|
||||
$table->bigIncrements('id');
|
||||
$table->unsignedBigInteger('base_id');
|
||||
$table->string('key',100);
|
||||
$table->string('code',10);
|
||||
$table->mediumText('text')->nullable();
|
||||
$table->tinyInteger('status')->default(0);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::table('language_translate', function (Blueprint $table) {
|
||||
$table->foreign('base_id')->references('id')->on('language_base');
|
||||
$table->foreign('key')->references('key')->on('language_base');
|
||||
$table->foreign('code')->references('code')->on('language');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
//
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,48 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class AddDataToPropertyAdditionalInfoKey extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
DB::table('property_additional_info_key')->insert(
|
||||
[
|
||||
[
|
||||
'additional_info_key' => 'locale_name_language',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'additional_info_key' => 'locale_name',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
]
|
||||
]
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
DB::connection()->statement("DELETE FROM property_additional_info_key WHERE additional_info_key = 'locale_name_language' ");
|
||||
DB::connection()->statement("DELETE FROM property_additional_info_key WHERE additional_info_key = 'locale_name' ");
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,32 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class AddColumnRoomBedType extends Migration
|
||||
{
|
||||
public function up()
|
||||
{
|
||||
Schema::table('property_room_bed_type', function (Blueprint $table) {
|
||||
$table->string('icon',30)->after('name')->nullable();
|
||||
});
|
||||
|
||||
DB::connection()->statement("UPDATE property_room_bed_type SET icon = '1.png' WHERE id = 1");
|
||||
DB::connection()->statement("UPDATE property_room_bed_type SET icon = '1.png' WHERE id = 2");
|
||||
DB::connection()->statement("UPDATE property_room_bed_type SET icon = '1.png' WHERE id = 3");
|
||||
DB::connection()->statement("UPDATE property_room_bed_type SET icon = '1.png' WHERE id = 4");
|
||||
DB::connection()->statement("UPDATE property_room_bed_type SET icon = '1.png' WHERE id = 5");
|
||||
DB::connection()->statement("UPDATE property_room_bed_type SET icon = '1.png' WHERE id = 6");
|
||||
DB::connection()->statement("UPDATE property_room_bed_type SET icon = '1.png' WHERE id = 7");
|
||||
DB::connection()->statement("UPDATE property_room_bed_type SET icon = '1.png' WHERE id = 8");
|
||||
}
|
||||
|
||||
|
||||
public function down()
|
||||
{
|
||||
Schema::table('property_room_bed_type', function (Blueprint $table) {
|
||||
$table->dropColumn('icon');
|
||||
});
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,34 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class ChangeColumnsExecutiveContactNameAndPropertyIdFields extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
DB::statement('SET FOREIGN_KEY_CHECKS=0;');
|
||||
DB::table('property_executive')->truncate();
|
||||
DB::statement('SET FOREIGN_KEY_CHECKS=1;');
|
||||
|
||||
Schema::table('property_executive', function (Blueprint $table) {
|
||||
$table->unique(['property_id', 'name_surname']);
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
//
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,37 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class UpdateDataToSiteConfig extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
$profileRateMapping = <<<EOT
|
||||
{"dashboard_section":{"general":{"title":"General","icon":"/img/hede.jpeg","description":"Here you can enter general information such as title, type, contact information, address and location of the property.","menus":[{"id":null,"name":"Information","type":0,"icon":"","alias":"Property.Information.Update","url":"/general-information"},{"id":null,"name":"Location","type":0,"icon":"","alias":"Property.Contact.List","url":"/location"},{"id":null,"name":"Facility","type":0,"icon":"","alias":"Property.Contact.List","url":"/facility-contact"},{"id":null,"name":"Contact","type":0,"icon":"","alias":"Property.Executive.List","url":"/executive-contact"},{"id":null,"name":"Brand","type":0,"icon":"","alias":"Property.Brand.Get","url":"/brand"}]},"amenities":{"title":"Amenities","icon":"","description":"Otel iç mekan , dış mekan , oda tipleri gibi bir çok içeriği buradan güncellemeye başkayabilirsin."},"facility":{"title":"Facility","icon":"","description":"Tesisin ödeme şekli, konaklama tipi, ulaşım hizmetleri, ortak kullanım alanları gibi genel tesis özelliklerini buradan seçebilirsin"},"room":{"title":"Room","icon":"","description":"Enter and edit room and common amenities of rooms details here"}}}
|
||||
EOT;
|
||||
|
||||
$profileHint = <<<EOT
|
||||
[{"title":"Lorem ipsum dolor sit amet, consectetur adipiscing elit","content":"Lorem ipsum dolor sit amet, consectetur adipiscing elit. Pellentesque tellus ex, posuere vitae lectus tempus","icon":"icon","url":null},{"title":"Lorem ipsum dolor sit amet, consectetur adipiscing elit","content":"Lorem ipsum dolor sit amet, consectetur adipiscing elit. Pellentesque tellus ex, posuere vitae lectus tempus","icon":"icon","url":null},{"title":"Lorem ipsum dolor sit amet, consectetur adipiscing elit","content":"Lorem ipsum dolor sit amet, consectetur adipiscing elit. Pellentesque tellus ex, posuere vitae lectus tempus","icon":"icon","url":null},{"title":"Lorem ipsum dolor sit amet, consectetur adipiscing elit","content":"Lorem ipsum dolor sit amet, consectetur adipiscing elit. Pellentesque tellus ex, posuere vitae lectus tempus","icon":"icon","url":null},{"title":"Lorem ipsum dolor sit amet, consectetur adipiscing elit","content":"Lorem ipsum dolor sit amet, consectetur adipiscing elit. Pellentesque tellus ex, posuere vitae lectus tempus","icon":"icon","url":null}]
|
||||
EOT;
|
||||
|
||||
DB::table('site_config')->where('config_key' , 'profile_rate_mapping')->update(['config_value_json' => $profileRateMapping]);
|
||||
DB::table('site_config')->where('config_key' , 'hint_list')->update(['config_value_json' => $profileHint]);
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
45
database/migrations/2020_07_02_092052_drop_locale_tables.php
Normal file
45
database/migrations/2020_07_02_092052_drop_locale_tables.php
Normal file
@@ -0,0 +1,45 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class DropLocaleTables extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
|
||||
Schema::table('property', function (Blueprint $table) {
|
||||
$table->dropColumn('destination_id');
|
||||
});
|
||||
Schema::dropIfExists('currency_locale');
|
||||
Schema::dropIfExists('language_locale');
|
||||
Schema::dropIfExists('permission_locale');
|
||||
Schema::dropIfExists('property_additional_info_key_locale');
|
||||
Schema::dropIfExists('property_channel_category_locale');
|
||||
Schema::dropIfExists('property_content_category_locale');
|
||||
Schema::dropIfExists('property_executive_type_locale');
|
||||
Schema::dropIfExists('property_fact_attribute_locale');
|
||||
Schema::dropIfExists('property_fact_locale');
|
||||
Schema::dropIfExists('property_photo_category_locale');
|
||||
Schema::dropIfExists('property_room_bed_type_locale');
|
||||
Schema::dropIfExists('property_room_type_locale');
|
||||
Schema::dropIfExists('property_type_locale');
|
||||
Schema::dropIfExists('property_unit_locale');
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
//
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,75 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class AddLanguageKeyToTables extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::table('currency', function (Blueprint $table) {
|
||||
$table->string('language_key',128)->after('name')->nullable();
|
||||
});
|
||||
Schema::table('language', function (Blueprint $table) {
|
||||
$table->string('language_key',128)->after('name')->nullable();
|
||||
});
|
||||
Schema::table('property_channel_category', function (Blueprint $table) {
|
||||
$table->string('language_key',255)->after('name')->nullable();
|
||||
});
|
||||
Schema::table('property_content_category', function (Blueprint $table) {
|
||||
$table->string('language_key',255)->after('name')->nullable();
|
||||
});
|
||||
Schema::table('property_executive_type', function (Blueprint $table) {
|
||||
$table->string('language_key',255)->after('name')->nullable();
|
||||
});
|
||||
Schema::table('property_fact_attribute', function (Blueprint $table) {
|
||||
$table->string('language_key',255)->after('name')->nullable();
|
||||
});
|
||||
Schema::table('property_fact', function (Blueprint $table) {
|
||||
$table->string('language_key',250)->after('name')->nullable();
|
||||
});
|
||||
Schema::table('property_photo_category', function (Blueprint $table) {
|
||||
$table->string('language_key',80)->after('category_name')->nullable();
|
||||
});
|
||||
Schema::table('property_room_bed_type', function (Blueprint $table) {
|
||||
$table->string('language_key',255)->after('name')->nullable();
|
||||
});
|
||||
Schema::table('property_room_type', function (Blueprint $table) {
|
||||
$table->string('language_key',255)->after('name')->nullable();
|
||||
});
|
||||
Schema::table('property_type', function (Blueprint $table) {
|
||||
$table->string('language_key',255)->after('name')->nullable();
|
||||
});
|
||||
Schema::table('property_unit', function (Blueprint $table) {
|
||||
$table->string('language_key',128)->after('name')->nullable();
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::table('currency', function (Blueprint $table) { $table->dropColumn('language_key'); });
|
||||
Schema::table('language', function (Blueprint $table) { $table->dropColumn('language_key'); });
|
||||
Schema::table('property_channel_category', function (Blueprint $table) { $table->dropColumn('language_key'); });
|
||||
Schema::table('property_content_category', function (Blueprint $table) { $table->dropColumn('language_key'); });
|
||||
Schema::table('property_executive_type', function (Blueprint $table) { $table->dropColumn('language_key'); });
|
||||
Schema::table('property_fact_attribute', function (Blueprint $table) { $table->dropColumn('language_key'); });
|
||||
Schema::table('property_fact', function (Blueprint $table) { $table->dropColumn('language_key'); });
|
||||
Schema::table('property_photo_category', function (Blueprint $table) { $table->dropColumn('language_key'); });
|
||||
Schema::table('property_room_bed_type', function (Blueprint $table) { $table->dropColumn('language_key'); });
|
||||
Schema::table('property_room_type', function (Blueprint $table) { $table->dropColumn('language_key'); });
|
||||
Schema::table('property_type', function (Blueprint $table) { $table->dropColumn('language_key'); });
|
||||
Schema::table('property_unit', function (Blueprint $table) { $table->dropColumn('language_key'); });
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,42 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreateTablePropertyRoomViewTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('property_room_view_type', function (Blueprint $table) {
|
||||
$table->bigIncrements('id');
|
||||
$table->string('name',100);
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::table('property_room_view_type', function (Blueprint $table) {
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('property_room_view_type');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,45 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePropertyRoomViewMappingTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('property_room_view_mapping', function (Blueprint $table) {
|
||||
$table->bigIncrements('id');
|
||||
$table->unsignedBigInteger('room_id');
|
||||
$table->unsignedBigInteger('room_view_type_id');
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
});
|
||||
|
||||
Schema::table('property_room_view_mapping', function (Blueprint $table) {
|
||||
$table->unique(['room_id','room_view_type_id']);
|
||||
$table->foreign('room_id')->references('id')->on('property_room');
|
||||
$table->foreign('room_view_type_id')->references('id')->on('property_room_view_type');
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('property_room_view_mapping');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,327 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class AddDataPropertyTypeTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
DB::statement('SET FOREIGN_KEY_CHECKS=0;');
|
||||
DB::table('property_type')->truncate();
|
||||
DB::statement('SET FOREIGN_KEY_CHECKS=1;');
|
||||
|
||||
DB::table('property_type')->insert(
|
||||
[
|
||||
[
|
||||
'name' => '1 Star Hotel',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => '2 Star Hotel',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => '3 Star Hotel',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => '4 Star Hotel',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => '5 Star Hotel',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Apart Hotel',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Boutique Hotel',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Bungolow',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Cabin',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Capsule hotel',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Castle',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Chalet',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Condo',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Cottage',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Country house',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Farm stay',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Guest house',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Hostel',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Lodge',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Love hotel',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Motel',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Pansion',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Private Holiday Home',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Ranch',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Residence',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Resort',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Ryokan',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Safari tentalow',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Suit Hotel',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Thermal Facility ',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Town House',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Tree House ',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
]
|
||||
]
|
||||
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
DB::statement('SET FOREIGN_KEY_CHECKS=0;');
|
||||
DB::table('property_type')->truncate();
|
||||
DB::statement('SET FOREIGN_KEY_CHECKS=1;');
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,255 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class AddDataPropertyRoomTypeTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
DB::statement('SET FOREIGN_KEY_CHECKS=0;');
|
||||
DB::table('property_executive_type')->truncate();
|
||||
DB::statement('SET FOREIGN_KEY_CHECKS=1;');
|
||||
|
||||
DB::table('property_room_type')->insert(
|
||||
[
|
||||
[
|
||||
'name' => 'Accessible Room',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Apartment',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Attic',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Bungalow',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Club Room',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Deluxe',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Economy',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Family Room',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Grand Suite',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Junior Suite',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'King suite',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Pent House',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Premium Room',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Standart Room',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Suite',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Superior',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Villa',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Connection Room',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Studio Room',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Roh Room',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Loft Room',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Cabana Room',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Dublex Room',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Honeymoon Room',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
]
|
||||
]
|
||||
|
||||
);
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
DB::statement('SET FOREIGN_KEY_CHECKS=0;');
|
||||
DB::table('property_room_type')->truncate();
|
||||
DB::statement('SET FOREIGN_KEY_CHECKS=1;');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,145 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class AddDataPropertyRoomBedTypeTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
DB::statement('SET FOREIGN_KEY_CHECKS=0;');
|
||||
DB::table('property_room_bed_type')->truncate();
|
||||
DB::statement('SET FOREIGN_KEY_CHECKS=1;');
|
||||
|
||||
DB::table('property_room_bed_type')->insert(
|
||||
[
|
||||
[
|
||||
'name' => 'Bunk Bed',
|
||||
'language_key' => '',
|
||||
'icon' => '1.png',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Double Bed',
|
||||
'language_key' => '',
|
||||
'icon' => '1.png',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'French Bed',
|
||||
'language_key' => '',
|
||||
'icon' => '1.png',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Futon',
|
||||
'language_key' => '',
|
||||
'icon' => '1.png',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'King Bed',
|
||||
'language_key' => '',
|
||||
'icon' => '1.png',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Queen Bed',
|
||||
'language_key' => '',
|
||||
'icon' => '1.png',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Single Bed',
|
||||
'language_key' => '',
|
||||
'icon' => '1.png',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Sofa Bed',
|
||||
'language_key' => '',
|
||||
'icon' => '1.png',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Twin Bed',
|
||||
'language_key' => '',
|
||||
'icon' => '1.png',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
]
|
||||
|
||||
]
|
||||
|
||||
);
|
||||
|
||||
DB::statement('SET FOREIGN_KEY_CHECKS=0;');
|
||||
DB::table('property_executive_type')->truncate();
|
||||
DB::statement('SET FOREIGN_KEY_CHECKS=1;');
|
||||
|
||||
$result = DB::table('property_executive_type')->insert(
|
||||
[
|
||||
'name' => 'Accounting',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
]
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
DB::statement('SET FOREIGN_KEY_CHECKS=0;');
|
||||
DB::table('property_room_bed_type')->truncate();
|
||||
DB::statement('SET FOREIGN_KEY_CHECKS=1;');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,73 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreatePropertyWebTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
|
||||
Schema::create('property_web_template', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->string('name', 128)->unique();
|
||||
$table->string('folder_name', 200);
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
|
||||
});
|
||||
|
||||
|
||||
Schema::create('property_web', function (Blueprint $table) {
|
||||
$table->bigIncrements('id');
|
||||
$table->integer('property_id')->unsigned();
|
||||
$table->string('domain', 50)->unique();
|
||||
$table->string('default_language', 10)->default('en_EN');
|
||||
$table->unsignedInteger('template_id')->default(1);
|
||||
$table->string('token',128)->unique();
|
||||
$table->tinyInteger('status')->default(1);
|
||||
$table->unsignedInteger('created_by');
|
||||
$table->unsignedInteger('updated_by');
|
||||
$table->integer('created_at');
|
||||
$table->integer('updated_at');
|
||||
|
||||
$table->foreign('property_id')->references('id')->on('property');
|
||||
$table->foreign('template_id')->references('id')->on('property_web_template');
|
||||
|
||||
});
|
||||
|
||||
DB::table('property_web_template')->insert(
|
||||
[
|
||||
[
|
||||
'name' => 'Default Template',
|
||||
'folder_name' => 'default',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
]
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('property_web');
|
||||
Schema::dropIfExists('property_web_template');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,119 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class AddDataPropertyExecutiveTypeTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
DB::statement('SET FOREIGN_KEY_CHECKS=0;');
|
||||
DB::table('property_executive_type')->truncate();
|
||||
DB::statement('SET FOREIGN_KEY_CHECKS=1;');
|
||||
|
||||
DB::table('property_executive_type')->insert(
|
||||
[
|
||||
[
|
||||
'name' => 'Accounting',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Activity',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Finance',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Front Office',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Group',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Manager',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Reservation',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Sales and Marketing',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Others',
|
||||
'language_key' => '',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
]
|
||||
]
|
||||
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
DB::statement('SET FOREIGN_KEY_CHECKS=0;');
|
||||
DB::table('property_executive_type')->truncate();
|
||||
DB::statement('SET FOREIGN_KEY_CHECKS=1;');
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,30 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class ClearUniquePropertyExecutiveTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::table('property_executive', function (Blueprint $table) {
|
||||
$table->dropUnique(['property_id', 'name_surname']);
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
//
|
||||
}
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,37 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class ChangeColumnLanguageBaseAndLanguageTranslateClearForeingkeys extends Migration
|
||||
{
|
||||
|
||||
public function up()
|
||||
{
|
||||
Schema::table('language_base', function (Blueprint $table) {
|
||||
$table->dropForeign(['created_by']);
|
||||
$table->dropForeign(['updated_by']);
|
||||
});
|
||||
|
||||
Schema::table('language_translate', function (Blueprint $table) {
|
||||
$table->dropForeign(['created_by']);
|
||||
$table->dropForeign(['updated_by']);
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
public function down()
|
||||
{
|
||||
Schema::table('language_base', function (Blueprint $table) {
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
});
|
||||
|
||||
Schema::table('language_translate', function (Blueprint $table) {
|
||||
$table->foreign('created_by')->references('id')->on('user');
|
||||
$table->foreign('updated_by')->references('id')->on('user');
|
||||
});
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,104 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\DB;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class AddColumnAndCreateDataPropertyRoomViewTypeTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::table('property_room_view_type', function (Blueprint $table) {
|
||||
$table->string('language_key',100)->after('name')->nullable();
|
||||
});
|
||||
|
||||
DB::statement('SET FOREIGN_KEY_CHECKS=0;');
|
||||
DB::table('property_room_view_type')->truncate();
|
||||
DB::statement('SET FOREIGN_KEY_CHECKS=1;');
|
||||
|
||||
DB::table('property_room_view_type')->insert(
|
||||
[
|
||||
[
|
||||
'name' => 'Park',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Pool ',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'River',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Sea ',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Street',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Valley',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
],
|
||||
[
|
||||
'name' => 'Monument',
|
||||
'status' => 1,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1,
|
||||
'created_at' => 1,
|
||||
'updated_at' => 1,
|
||||
]
|
||||
]
|
||||
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::table('property_room_view_type', function (Blueprint $table) {
|
||||
$table->dropColumn('language_key');
|
||||
});
|
||||
|
||||
DB::statement('SET FOREIGN_KEY_CHECKS=0;');
|
||||
DB::table('property_room_view_type')->truncate();
|
||||
DB::statement('SET FOREIGN_KEY_CHECKS=1;');
|
||||
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,33 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class AddTitleLanguageKeyToPropertyFact extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::table('property_fact', function (Blueprint $table) {
|
||||
$table->string('title_language_key',250)->after('language_key')->nullable();
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::table('property_fact', function (Blueprint $table) {
|
||||
$table->dropColumn('title_language_key');
|
||||
});
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,68 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\DB;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class TruncateRelatedPropertyTables extends Migration
|
||||
{
|
||||
|
||||
public function up()
|
||||
{
|
||||
/*
|
||||
DB::statement('SET FOREIGN_KEY_CHECKS=0;');
|
||||
|
||||
DB::table('api_access_token')->truncate();
|
||||
DB::table('jobs')->truncate();
|
||||
DB::table('failed_jobs')->truncate();
|
||||
|
||||
DB::table('offer')->truncate();
|
||||
DB::table('offer_accommodation_mapping')->truncate();
|
||||
DB::table('offer_cancellation_policy')->truncate();
|
||||
DB::table('offer_contact_mapping')->truncate();
|
||||
DB::table('offer_fact_mapping')->truncate();
|
||||
DB::table('offer_important_notes')->truncate();
|
||||
DB::table('offer_photo_mapping')->truncate();
|
||||
DB::table('offer_price')->truncate();
|
||||
DB::table('offer_room_mapping')->truncate();
|
||||
|
||||
DB::table('property')->truncate();
|
||||
DB::table('property_additional_info')->truncate();
|
||||
DB::table('property_brand')->truncate();
|
||||
DB::table('property_channel_mapping')->truncate();
|
||||
DB::table('property_config')->truncate();
|
||||
DB::table('property_contact')->truncate();
|
||||
DB::table('property_content')->truncate();
|
||||
DB::table('property_executive')->truncate();
|
||||
DB::table('property_fact_attribute_mapping')->truncate();
|
||||
DB::table('property_fact_mapping')->truncate();
|
||||
DB::table('property_module_mapping')->truncate();
|
||||
DB::table('property_photo')->truncate();
|
||||
DB::table('property_room')->truncate();
|
||||
DB::table('property_room_availability')->truncate();
|
||||
DB::table('property_room_bed')->truncate();
|
||||
DB::table('property_room_fact_mapping')->truncate();
|
||||
DB::table('property_room_photo_mapping')->truncate();
|
||||
DB::table('property_room_rate')->truncate();
|
||||
DB::table('property_room_rate_channel_mapping')->truncate();
|
||||
DB::table('property_room_rate_inclusion_mapping')->truncate();
|
||||
DB::table('property_room_rate_mapping')->truncate();
|
||||
DB::table('property_room_rate_mapping_setup')->truncate();
|
||||
DB::table('property_room_rate_price')->truncate();
|
||||
DB::table('property_room_view_mapping')->truncate();
|
||||
DB::table('property_web')->truncate();
|
||||
|
||||
DB::table('user')->truncate();
|
||||
DB::table('user_property_mapping')->truncate();
|
||||
|
||||
DB::statement('SET FOREIGN_KEY_CHECKS=1;');
|
||||
*/
|
||||
}
|
||||
|
||||
|
||||
public function down()
|
||||
{
|
||||
//
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,34 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class AddIconToPropertyExecutiveType extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::table('property_executive_type', function (Blueprint $table) {
|
||||
$table->string('icon',32)->after('language_key')->nullable();
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::table('property_executive_type', function (Blueprint $table) {
|
||||
$table->dropColumn('icon');
|
||||
|
||||
});
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,30 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class AddLanguageKeyToTables extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::table('country', function (Blueprint $table) {
|
||||
$table->string('language_key',128)->after('name')->nullable();
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::table('country', function (Blueprint $table) { $table->dropColumn('language_key'); });
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class AddAccommodationTypeToPropertyRoomRate extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::table('property_room_rate', function (Blueprint $table) {
|
||||
$table->unsignedInteger('accommodation_type')->after('description');
|
||||
});
|
||||
\DB::table('property_room_rate')->update(['accommodation_type' => 13]);
|
||||
Schema::table('property_room_rate', function (Blueprint $table) {
|
||||
$table->foreign('accommodation_type', 'accommodation_type_foreign')->references('id')->on('property_fact');
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,25 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class AddRoomSizeToPropertyRoom extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
DB::statement("ALTER TABLE `property_room` ADD COLUMN `room_size` INT NULL AFTER `exclude_occupancy`");
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
|
||||
}
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user