osb/database/migrations/2017_06_18_104531_create_ab_currency_table.php
2018-06-18 21:18:34 +10:00

40 lines
843 B
PHP

<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
class CreateAbCurrencyTable extends Migration {
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('ab_currency', function(Blueprint $table)
{
$table->integer('id')->default(0)->primary();
$table->integer('country_id')->nullable()->index('fk_cur_cty_idx');
$table->string('name', 128)->nullable();
$table->boolean('active')->nullable();
$table->text('convert_array')->nullable();
$table->string('notes', 128)->nullable();
$table->string('symbol', 16)->nullable();
$table->string('three_digit', 3)->nullable()->unique('three_digit_UNIQUE');
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::drop('ab_currency');
}
}