ldc-com-app-bo/database/migrations/2021_01_15_100959_contacts_table.php
Vincent BRIDIER 6420f1d733 - Fix uuid size
- Change select1 select2
2021-01-19 09:58:21 +01:00

47 lines
1.3 KiB
PHP

<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class ContactsTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('contacts', function (Blueprint $table) {
$table->string('id', 50);
$table->string('email');
$table->string('type', 8);
$table->string('other', 50);
$table->string('select1', 50);
$table->string('select2', 50);
$table->string('name', 50);
$table->string('firstname', 50);
$table->string('company', 50);
$table->string('address', 255);
$table->string('phone', 50);
$table->string('products', 255);
$table->string('card_url', 255);
$table->text('notes');
$table->text('visits');
$table->unsignedBigInteger('user_id');
$table->foreign('user_id')->references('id')->on('app_users');
$table->timestamps();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('contacts');
}
}