imcode

3130 经验值

登录的时候,密码错误,怎么提示,而且阻止进入下一个环节

太棒了,就是更新有点慢,希望楼主更新快的

你这主题挺好看,能介绍一下吗

解决了

public function followThis($question){
    return $this->follows($question)->toggle($question);
}

这个方法应该 return $this->follows($question)->toggle($question); 这样写

Missing argument 1 for App\User::follows(), called in D:\code\php\zhihu\app\User.php on line 58 and defined

//关注
public function follows($question){
    return $this->belongsToMany(Question::class,'user_question')->withTimestamps();
}

public function followThis($question){
    return $this->follows()->toggle($question);
}