<?php

use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;

class CreateOrderedDocumentsTable extends Migration
{
   /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        if (!Schema::hasTable('ordered_document')) {
            Schema::create('ordered_document', function (Blueprint $table) {
                $table->increments('id');
                $table->string('tracking_no');
                $table->string('index_no');
                $table->string('applicant_name');
                $table->string('phone_no');
                $table->string('emailaddress');
                $table->string('postal_address');
                $table->string('type_of_document');
                $table->string('transaction_id');
                $table->string('delivery_mode');
                $table->string('status');
                $table->timestamps();
            });
        }
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('ordered_document');
    }
}
