id(); $table->integer('admin_id'); $table->integer('course_id'); $table->string('title')->comment('标题'); $table->string('slug')->comment('slug'); $table->string('url', 500)->default('')->comment('播放地址'); $table->integer('view_num')->default(0)->comment('观看次数'); $table->string('short_description', 500)->default('')->comment('简短介绍'); $table->text('description')->comment('详细介绍'); $table->timestamp('published_at')->default(null)->nullable(true)->comment('上线时间'); $table->string('aliyun_video_id')->default('')->nullable(); $table->string('tencent_video_id')->default('')->nullable(); $table->integer('course_chapter_id')->default(0); $table->integer('duration')->default(0)->comment('时长,单位:秒'); $table->tinyInteger('comment_status')->default(0)->comment('0禁止评论,1可以评论'); $table->string('subtitle_zh_path')->default('')->comment('中文字幕'); $table->string('subtitle_en_path')->default('')->comment('英文字幕'); $table->tinyInteger('ban_drag')->default(0)->comment('禁止拖动,0否,1是'); $table->integer('sort')->default(0); $table->tinyInteger('status')->comment('1显示,0隐藏'); $table->softDeletes(); $table->timestamps(); }); } /** * Reverse the migrations. * * @return void */ public function down() { Schema::dropIfExists('course_videos'); } }