directus-extension-computed-interface icon indicating copy to clipboard operation
directus-extension-computed-interface copied to clipboard

Unexpected Error when Primary Key Field Name is not `id`

Open avenjamin opened this issue 1 year ago • 0 comments

Took me a little while to debug, but looks like the primary key field name id is hard coded in the extension.

I was trying to calculate against a field via a M20 relationship and the foreign table primary key field was set to uuid instead of id.

Not sure if you can look up the primary key field name and use that or if you have to add an additional input field to allow us to specify the primary key field name. Or alternatively document that as a requirement.

Cheers Ben

avenjamin avatar Jan 18 '24 12:01 avenjamin