We have a sender model and an account_sender model. The latter belongs to sender (one-to-many relationship). When I visit the account_sender field in sender record Details tab and there’s no account_sender under it, it works correctly. But when there are account_senders belonging to the sender, I got following error in console:
Error: Expected id to be a string or number, received null
Could you please share you entire JS model definition of sender and account_sender please (especially the relationship parts)?
I’m seeing that you have a account_id field in your account_sender, is there an account table too?
Moreover, could you check if the id of the sender is never null and same for the sender_id of the account_sender table?
Moreover, if you’re trying it in your development environment, you’ll be able to see the request that is made and that is causing this issue. We might learn a bit more from it.
Hi @anon34731316, I might know why while looking into the request that you asked for.
We are using composite primary key in account_sender model, and seems it’s not yet supported: Composite primary key.
You’re right, composite keys are not well supported yet… Sorry for the inconvenience. I’m pushing your feedback to our Product roadmap.
On a side note: we have released a brand-new agent-nodejs (complete rework of the agent you are working on, more flexible, easier to use, etc.) and this agent supports composite keys.
We don’t have a clear documentation to migrate from the former agent to the new one yet. But if you want to give it a try soon, be sure we’ll be available to help you out.
Just wonder what else does this new agent support while the old one doesn’t. To see if it’s worth to ask the team to put effort into agent migration soon.