Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public function articles(){
- return $this->belongsToMany('AppArticle');
- }
- public function category(){
- return $this->hasOne('Appcategory');
- }
- $article->category()->sync($request->category, false);
Add Comment
Please, Sign In to add comment