<?php

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

class AddNongyaoToGoodTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::table('goods', function (Blueprint $table) {

            $table->string('register_name')->nullable()->comment('登记名称');
            $table->string('card_id')->nullable()->comment('农药登记证号');
            $table->string('duxing')->nullable()->comment('毒性');
            $table->string('jixing')->nullable()->comment('剂型');
            $table->string('shengchan_id')->nullable()->comment('生产批准证号');
            $table->string('changpin_id')->nullable()->comment('产品标准号');
            $table->string('guige')->nullable()->comment('产品规格');
            $table->string('baozhiqi')->nullable()->comment('保质期');
            $table->text('yongtu')->nullable()->comment('产品性能-用途');
            $table->text('cuncu')->nullable()->comment('存储方法');
            $table->text('zhongdu')->nullable()->comment('中毒急救');
            $table->text('zhuyi')->nullable()->comment('注意事项');
            $table->string('youxiao')->nullable()->comment('有效成分');
            $table->string('company')->nullable()->comment('企业名称');
            $table->string('tel')->nullable()->comment('技术热线');
            $table->string('address')->nullable()->comment('公司地址');


        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::table('goods', function (Blueprint $table) {
            $table->dropColumn(['register_name', 'card_id', 'duxing', 'jixing', 'shengchan_id', 'changpin_id', 'guige', 'baozhiqi', 'yongtu', 'zhuyi', 'youxiao', 'company', 'tel', 'address']);
        });
    }
}
