2015-03-24 15:07:38 +10:30
|
|
|
<?php
|
2016-11-29 05:03:53 +00:00
|
|
|
|
2015-08-26 16:18:58 +09:30
|
|
|
/*
|
|
|
|
* This file is part of Flarum.
|
|
|
|
*
|
2019-11-28 00:16:50 +00:00
|
|
|
* For detailed copyright and license information, please view the
|
|
|
|
* LICENSE file that was distributed with this source code.
|
2015-08-26 16:18:58 +09:30
|
|
|
*/
|
|
|
|
|
2016-02-25 00:50:54 +09:00
|
|
|
use Flarum\Database\Migration;
|
2015-03-24 15:07:38 +10:30
|
|
|
use Illuminate\Database\Schema\Blueprint;
|
|
|
|
|
2016-02-25 00:50:54 +09:00
|
|
|
return Migration::createTable(
|
|
|
|
'notifications',
|
|
|
|
function (Blueprint $table) {
|
|
|
|
$table->increments('id');
|
|
|
|
$table->integer('user_id')->unsigned();
|
|
|
|
$table->integer('sender_id')->unsigned()->nullable();
|
|
|
|
$table->string('type', 100);
|
|
|
|
$table->string('subject_type', 200)->nullable();
|
|
|
|
$table->integer('subject_id')->unsigned()->nullable();
|
|
|
|
$table->binary('data')->nullable();
|
|
|
|
$table->dateTime('time');
|
|
|
|
$table->boolean('is_read')->default(0);
|
|
|
|
$table->boolean('is_deleted')->default(0);
|
2015-05-19 01:22:09 +02:00
|
|
|
}
|
2016-02-25 00:50:54 +09:00
|
|
|
);
|