sapalymahabat/plugins/site21/fields/updates/create_fields_table.php

27 lines
689 B
PHP

<?php namespace Site21\Fields\Updates;
use Schema;
use October\Rain\Database\Schema\Blueprint;
use October\Rain\Database\Updates\Migration;
class CreateFieldsTable extends Migration
{
public function up()
{
Schema::create('site21_shopaholic_fields', function (Blueprint $table) {
$table->engine = 'InnoDB';
$table->increments('id');
$table->string('name');
$table->string('slug');
$table->string('type');
$table->boolean('active')->default(true);
$table->timestamps();
});
}
public function down()
{
Schema::dropIfExists('site21_shopaholic_fields');
}
}