shareit/database/migrations/2018_09_10_233609_item_user.php

34 lines
666 B
PHP
Raw Normal View History

2018-09-11 00:30:00 +00:00
<?php
use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
2018-09-11 23:48:09 +00:00
class ItemUser extends Migration
2018-09-11 00:30:00 +00:00
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
2018-09-11 23:48:09 +00:00
Schema::create('item_user', function (Blueprint $table) {
2018-09-11 00:30:00 +00:00
$table->increments('id');
2018-09-11 23:48:09 +00:00
$table->integer('item_id');
$table->integer('user_id');
2018-09-11 00:30:00 +00:00
$table->timestamps();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
2018-09-11 23:48:09 +00:00
Schema::dropIfExists('item_user');
2018-09-11 00:30:00 +00:00
}
}