relationships for local key and foreign key in UserRole relationship

This commit is contained in:
2018-11-05 09:27:17 -06:00
parent 99af5b41cf
commit 7169a25133
2 changed files with 3 additions and 3 deletions

View File

@@ -13,6 +13,6 @@ class UserRole extends Model
public $timestamps = true;
public function user() {
return $this->belongsTo('App\User');
return $this->belongsTo('App\User', 'character_id', 'user_id');
}
}