为什么php artisan迁移失败:未定义的方法?

时间:2016-11-24 05:28:02

标签: php laravel command-line command-prompt laravel-5.3

查看此图片:https://postimg.org/image/4fvu34juz/

当我运行php artisan migrate时,会显示:

<?php

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

class CreateFlightTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        //
        Schema::create('flights', function (Blueprint $table) {
            $table->increments('id');
            $table->string('name');
            $table->string('airline');
            $table->timestamps();
        });
    }

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

解决我问题的任何解决方案?

更新:

代码:

{
  "entryName": "fb-api",
  "profile": "rtmp-facebook",
  "sourceStreamName": "{StreamName}",
  "facebook.title": "Live Test",
  "facebook.destType": "timeline",
  "facebook.destId": "{DestinationPageId}",
  "facebook.destName": "My Timeline",
  "facebook.description": "This is Wowza live test",
  "facebook.accessToken": "{FacebookAccessToken}",
  "facebook.privacy": "onlyMe",
  "extraOptions": {
    "destinationName": "facebook"
  },
  "enabled": true
}

1 个答案:

答案 0 :(得分:1)

这意味着类textarea()中没有名为Blueprint的函数。删除调用它的代码。