我正在尝试对laravel ORM有一个感觉,我有以下几个模型。with- id,firstname,lastname city table with - id,name usercity table with - user_id,city_id public function user() return $this->belongsTo('App\User');现在,目标是检索用户访问过的所有城市
我正在试图获得一份名单,用户的ID谁读一个特定的杂志。
name
progress_value
thing_progress_id (FK from thing_progresses table)user_id (FK from users table)namespace App\Models;
class