<?php

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

class CreateProductionRecipesTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('production_recipes', function (Blueprint $table) {
            $table->id();
            $table->unsignedBigInteger('product_finished_id')->nullable();
            $table->unsignedBigInteger('product_material_id')->nullable();
            $table->unsignedBigInteger('multi_unit_finished')->nullable();
            $table->unsignedBigInteger('multi_unit_material')->nullable();
            $table->integer('qty_finished')->nullable();
            $table->integer('qty_material')->nullable();
            $table->timestamps();
        });
    }

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