Closed redleon00 closed 1 year ago
Hey @redleon00,
from memory, you can do that using the transform
property when defining a column https://github.com/jamesdordoy/laravel-vue-datatable#column-props
e.g.
{
name: 'first_name',
label: 'Full Name',
transform: (row) => { return row.first_name + ' ' + row.last_name }
}
Shout if that dosnt work but think it should
Thx u @jamesdordoy for your response, ok i this moment i resolve ir using a map function with the data but i will try your solution.
transform: ({data}) => { return data.owner.name + ' ' + data.owner.last_name }
That is the solution, only have to change row for data and the braquets, thx u @jamesdordoy
Hi, i'm using laravel-vue-datatable but i don't know how i can concat two columns from the data, how i can do it?