Changeset c6b84df for database/migrations
- Timestamp:
- 10/21/21 23:45:59 (3 years ago)
- Branches:
- develop, master
- Children:
- 4b7e2d3
- Parents:
- 6b95845
- Location:
- database/migrations
- Files:
-
- 2 added
- 2 edited
- 1 moved
Legend:
- Unmodified
- Added
- Removed
-
database/migrations/2021_09_27_171107_create_users_table.php
r6b95845 rc6b84df 20 20 $table->string('surname'); 21 21 $table->string('username')->unique(); 22 $table->string('password');23 22 $table->string('email')->unique(); 24 23 $table->string('phone_number')->unique(); … … 30 29 $table->boolean('is_confirmed')->default(false); 31 30 $table->boolean('is_forgot_password')->default(false); 31 $table->integer("created_by")->unsigned(); 32 32 $table->integer('security_code')->nullable(); 33 33 $table->string('verify_token')->nullable(); 34 $table-> integer("created_by")->unsigned();34 $table->string('password'); 35 35 $table->rememberToken(); 36 36 $table->timestamps(); -
database/migrations/2021_10_06_103305_create_folders_table.php
r6b95845 rc6b84df 5 5 use Illuminate\Support\Facades\Schema; 6 6 7 class Create DocumentsTable extends Migration7 class CreateFoldersTable extends Migration 8 8 { 9 9 /** … … 14 14 public function up() 15 15 { 16 Schema::create(' documents', function (Blueprint $table) {16 Schema::create('folders', function (Blueprint $table) { 17 17 $table->bigIncrements('id'); 18 18 $table->string("arch_id")->unique(); 19 19 $table->string("name"); 20 $table->text("description"); 20 $table->text("note")->nullable(); 21 $table->string("location"); 21 22 $table->integer("user_id")->unsigned(); 22 23 $table->integer("department_id")->unsigned(); 23 $table->boolean("is_important")->default( true);24 $table->boolean("is_important")->default(false); 24 25 $table->timestamps(); 25 26 … … 36 37 public function down() 37 38 { 38 Schema::dropIfExists(' documents');39 Schema::dropIfExists('folders'); 39 40 } 40 41 } -
database/migrations/2021_10_10_103309_create_files_table.php
r6b95845 rc6b84df 16 16 Schema::create('files', function (Blueprint $table) { 17 17 $table->bigIncrements('id'); 18 $table->bigInteger(' document_id')->unsigned();18 $table->bigInteger('folder_id')->unsigned(); 19 19 $table->string("name"); 20 20 $table->string("location"); 21 $table->foreign(" document_id")->references("id")->on("documents");21 $table->foreign("folder_id")->references("id")->on("folders"); 22 22 $table->timestamps(); 23 23 });
Note:
See TracChangeset
for help on using the changeset viewer.