Error when trying to sort table by MorphTo relationship
I have a table with a model (
but when I try to view the table, I get this:
The
I have confirmed:
Is anyone able to give me a hand?
Person) and that model has a MorphTo relationship type called user(). In generating the table, I'm trying to do the following (some fields removed for the example but they do not matter):but when I try to view the table, I get this:
The
where "laravel_reserved_0"."" looks suspicious to me (why is the column name blank?), and I suspect it has something to do with the MorphTo relationship, but I'm not clear where to even continue looking and troubleshooting.I have confirmed:
- Without the
defaultSort(), the table displays the correctuser.namevalue so it's something to do with this call - Every
Personhas a valid
anduser_iduser_typeentry filled in - Every referenced
has a valid (non-null)user_id
valuename
live() to the email address field which lives on the same user relationship, it doesn't actually fire. I can see the network call to /update happening in the Dev Console, but there's no data in the components.0.effects.returns array which I assume is where any validation errors would otherwise appear?Is anyone able to give me a hand?