laravel7でPostのユーザ毎の既読管理
laravel7でPostのユーザ毎の既読管理 1, Read(既読)管理テーブルを作る。レコードが存在したら既読
1 2 3 4 5 6 |
Schema::create('reads', function (Blueprint $table) { $table->id(); $table->unsignedBigInteger('post_id')->comment('投稿記事'); $table->unsignedBigInteger('user_id')->comment('このユーザーの未読・既読'); $table->timestamps(); }); |
2, POST記事を見たら、既読レコー 続きを読む laravel7でPostのユーザ毎の既読管理