yajra / laravel-datatables

jQuery DataTables API for Laravel

Home Page:https://yajrabox.com/docs/laravel-datatables

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Question: Unknow column 'name' when using laravel/translations

minhkhoablieu opened this issue · comments

Hi.
I have 2 tables: categories and category_translations.
Table categories has columns as image below.
image

and this is the column of the category_translation table
image

and I can't get the name column it shows the error Unknown column 'name'
image

This is the code where I initialize the datatables at line 0, I call {{ $category->translate('vi')->name }} according to the instructions of the document I am using
image
Can you help me? Thank you