Dynamic Columns Based on Joins #848
Unanswered
swarrenwecareconnectorg
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I'm working on an application that allows users to have custom fields associated with each user based on options their organization selectes. I need to be able to display a set of fixed columns (first name, last name, email, etc) and the custom fields in the same laravel-livewire-tables table. I'm struggling with how to set this up in this library.
In my
public function builder()
function I loop through all the possible fields and add them as a join.Then I'm stuck when I create the columns function
I've tried aliasing the name of the column in the builder and putting the
"{$joinName}.value"
and they both try to load as a relationship when it's a value I want to pull from the query.Any ideas?
Beta Was this translation helpful? Give feedback.
All reactions