mirror of
https://github.com/BookStackApp/BookStack.git
synced 2025-07-30 04:23:11 +03:00
Started working on chapters
This commit is contained in:
@ -15,7 +15,7 @@ class CreatePagesTable extends Migration
|
||||
Schema::create('pages', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->integer('book_id');
|
||||
$table->integer('page_id');
|
||||
$table->integer('chapter_id');
|
||||
$table->string('name');
|
||||
$table->string('slug')->indexed();
|
||||
$table->longText('html');
|
||||
|
@ -0,0 +1,35 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class CreateChaptersTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('chapters', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->integer('book_id');
|
||||
$table->string('slug')->indexed();
|
||||
$table->text('name');
|
||||
$table->text('description');
|
||||
$table->integer('priority');
|
||||
$table->timestamps();
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::drop('chapters');
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user