turkmentv/database/migrations/2019_05_31_205304_create_pr...

40 lines
1.0 KiB
PHP

<?php
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
class CreateProgrammesTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('programmes', function (Blueprint $table) {
$table->increments('id');
$table->string('name');
$table->longText('altyn')->nullable();
$table->longText('yashlyk')->nullable();
$table->longText('miras')->nullable();
$table->longText('turkmenistan')->nullable();
$table->longText('owaz')->nullable();
$table->longText('sport')->nullable();
$table->unsignedInteger('page_id')->nullable();
$table->foreign('page_id')->references('id')->on('pages');
$table->timestamps();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('programmes');
}
}