问题 I'm extending the rainlab.user plugin to allow each user to have friends via a simple intermediate table with the following fields: user_id friend_id status I've extended the User model: use RainLab\User\Models\User as FrontUser; FrontUser::extend(function($model) { $model->belongsToMany['friends']=[ 'RainLab\User\Models\User', 'table' => 'meysam_social_friends', 'pivot' => ['status'], 'pivotModel' => 'Meysam\Social\Models\FriendsPivot', 'timestamps' => true, 'key' => 'user_id', 'otherKey' =>