#Problem when saving a post with categories - is this a bug?

13 messages ยท Page 1 of 1 (latest)

uncut ravine
#

Hello folks!

I have a collection of posts that have a collection of categories associated with it. When I select the category and click save, the post is saved successfully, but the selected category is not shown in the select. In order for me to see the category I need to reload the page. If I don't reload the page, make any changes to the post and save again I get an error: "The following field is invalid: category". Is this a bug or am I doing something wrong?

Thank you very much!

lyric widgetBOT
uncut ravine
#

I just noticed that this problem only occurs when hasMany is set to true!!!

sharp gale
#

hey @uncut ravine, I tried to recreate your issue but am not seeing the same thing. There might be an issue with the way you have set it up. Can you share your Category collection config here so I can see if I spot any problems?

uncut ravine
#

This is the categories collection

#

Thanks for your time!

sharp gale
#

@uncut ravine everything here looks correct to me. What version of Payload are you running? I know there have been a couple patch releases related to relationships, perhaps this issue was one of them

sharp gale
uncut ravine
sharp gale