id(); $table->integer('itemid')->comment('商品id'); $table->integer('typeid')->comment(''); $table->string('product_name')->comment('商品名'); $table->string('product_code')->index()->comment('商品code'); $table->string('product_group')->comment('商品组'); $table->decimal('market_price')->comment('市场价'); $table->decimal('settlement')->comment('结算价'); $table->integer('category_id')->index()->comment('分类id'); $table->string('category_name')->comment('分类名'); $table->tinyInteger('state')->default(1)->comment('状态 1上架 0 下架'); $table->timestamps(); }); } /** * Reverse the migrations. * * @return void */ public function down() { Schema::dropIfExists('goods'); } }