first commit

This commit is contained in:
denisdulici
2017-09-14 22:21:00 +03:00
commit 515bdaf5cd
598 changed files with 48030 additions and 0 deletions

View File

@ -0,0 +1,44 @@
<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
class CreateCustomersTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('customers', function (Blueprint $table) {
$table->increments('id');
$table->integer('company_id');
$table->integer('user_id')->nullable();
$table->string('name');
$table->string('email');
$table->string('tax_number')->nullable();
$table->string('phone')->nullable();
$table->text('address')->nullable();
$table->string('website')->nullable();
$table->string('currency_code');
$table->boolean('enabled');
$table->timestamps();
$table->softDeletes();
$table->index('company_id');
$table->unique(['company_id', 'email', 'deleted_at']);
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::drop('customers');
}
}