| 1234567891011121314151617181920212223242526272829303132333435 | 
							- <?php
 
- use Illuminate\Support\Facades\Schema;
 
- use Illuminate\Database\Schema\Blueprint;
 
- use Illuminate\Database\Migrations\Migration;
 
- class CreateContentsTable extends Migration
 
- {
 
-     /**
 
-      * Run the migrations.
 
-      *
 
-      * @return void
 
-      */
 
-     public function up()
 
-     {
 
-         Schema::create('contents', function (Blueprint $table) {
 
-             $table->increments('id');
 
-             $table->tinyInteger('type')->nullable()->comment('类型:1公告;2活动;3视频;4文章');
 
-             $table->string('title', 200)->nullable()->comment('标题');
 
-             $table->text('content')->nullable()->comment('内容');
 
-             $table->unsignedInteger('sort')->nullable()->default(0)->comment('排序');
 
-             $table->timestamps();
 
-         });
 
-     }
 
-     /**
 
-      * Reverse the migrations.
 
-      *
 
-      * @return void
 
-      */
 
-     public function down()
 
-     {
 
-         Schema::dropIfExists('contents');
 
-     }
 
- }
 
 
  |