<?php

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

class CreatePatientsTable extends Migration
{
    /*
     * Run the migrations.
     *
     * @return void
     */

    public function up()
    {

        /*
         * Table: patients
         */
        Schema::create('patients', function ($table) {
            $table->increments('id');
            $table->integer('user_id')->nullable();
            $table->string('user_type', 255)->nullable();
            $table->string('name', 50)->nullable();
            $table->string('ward', 50)->nullable();
            $table->string('diet', 50)->nullable();
            $table->time('food_expiry_time')->nullable();
            $table->date('food_issue_date')->nullable();
            $table->integer('bed_no')->nullable();
            $table->softDeletes();
            $table->nullableTimestamps();
        });
    }

    /*
    * Reverse the migrations.
    *
    * @return void
    */

    public function down()
    {
        Schema::drop('patients');
    }
}