comment('消息表'); $table->id(); $table->integer('dialogue_id')->nullable()->comment('对话id'); // 用户id $table->integer('user_id')->nullable()->comment('用户id'); // 接收人id $table->integer('to_user_id')->nullable()->comment('接收人id'); // 需求id $table->integer('supply_demand_id')->nullable()->comment('需求id'); // 消息内容 $table->text('content')->nullable()->comment('消息内容'); // 接收方是否已读 $table->tinyInteger('is_read')->nullable()->default(0)->comment('接收方是否已读0否1是'); $table->timestamps(); $table->softDeletes(); }); } /** * Reverse the migrations. * * @return void */ public function down() { Schema::dropIfExists('massages'); } };