id(); $table->unsignedBigInteger('user_id'); $table->foreign('user_id')->references('id')->on('users')->onDelete('cascade'); $table->string('title')->nullable(); $table->string('type')->nullable(); $table->text('message')->nullable(); $table->json('extra_fields')->nullable(); $table->enum('status', [0,1])->comment('0=> Unread, 1=>Read')->default(0); $table->timestamps(); }); } /** * Reverse the migrations. * * @return void */ public function down() { Schema::dropIfExists('notifications'); } }