From 242be736612c5c27c515046d4f7c48c3c308912e Mon Sep 17 00:00:00 2001 From: HDVinnie Date: Sun, 2 Dec 2018 22:42:57 -0500 Subject: [PATCH] (Add) Migrations - this branch will cover #220 --- ...12_03_024251_create_applications_table.php | 38 +++++++++++++++++++ ..._create_application_image_proofs_table.php | 33 ++++++++++++++++ ...12_create_application_url_proofs_table.php | 33 ++++++++++++++++ 3 files changed, 104 insertions(+) create mode 100644 database/migrations/2018_12_03_024251_create_applications_table.php create mode 100644 database/migrations/2018_12_03_032701_create_application_image_proofs_table.php create mode 100644 database/migrations/2018_12_03_032712_create_application_url_proofs_table.php diff --git a/database/migrations/2018_12_03_024251_create_applications_table.php b/database/migrations/2018_12_03_024251_create_applications_table.php new file mode 100644 index 0000000000..19293bf24f --- /dev/null +++ b/database/migrations/2018_12_03_024251_create_applications_table.php @@ -0,0 +1,38 @@ +increments('id'); + $table->string('type'); + $table->string('email')->unique(); + $table->longText('refferer')->nullable(); + $table->tinyInteger('status')->default(0); + $table->dateTime('moderated_at')->nullable(); + $table->integer('moderated_by')->nullable()->index(); + $table->integer('accepted_by')->nullable()->index(); + $table->timestamps(); + }); + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('applications'); + } +} diff --git a/database/migrations/2018_12_03_032701_create_application_image_proofs_table.php b/database/migrations/2018_12_03_032701_create_application_image_proofs_table.php new file mode 100644 index 0000000000..75834dd3f0 --- /dev/null +++ b/database/migrations/2018_12_03_032701_create_application_image_proofs_table.php @@ -0,0 +1,33 @@ +increments('id'); + $table->integer('application_id')->index(); + $table->string('image'); + $table->timestamps(); + }); + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('application_image_proofs'); + } +} diff --git a/database/migrations/2018_12_03_032712_create_application_url_proofs_table.php b/database/migrations/2018_12_03_032712_create_application_url_proofs_table.php new file mode 100644 index 0000000000..f6c0594b6f --- /dev/null +++ b/database/migrations/2018_12_03_032712_create_application_url_proofs_table.php @@ -0,0 +1,33 @@ +increments('id'); + $table->integer('application_id')->index(); + $table->string('url'); + $table->timestamps(); + }); + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('application_url_proofs'); + } +}