Laravel hasOne() Function Using $this when not in object context
I have 2 models named AdminContent, AdminCategory. I have content_category_id in my admin_contents table. I have category_id and category_name in my admin_categories table. I linked category_id with content_category_id foreign. I am using the hasOne() function in my Admin Content model.…