Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

216
Visualizações
Not able to add relational data to a collection type from post request in strapi v4

So I can add the relational data from the admin panel in strapi, so in this case there is a collection type called reviews and it has many to one relationship with another collection type called products

In postman when I add a review I’m not able to add relation to it. Currently I’m adding the relation via id as that is the standard.

I was able to do in this in v3, but in strapi v4 for some reason the relation is not getting added.

about 4 years ago · Juan Pablo Isaza
1 Respostas
Responde à pergunta

0

I had the same problem and solved it by going to "Settings" > "Users permissions plugins" > "Roles" > "Public" (or "Authenticated", depending on if you want only logged-in users to access it) > "Products" and click "find" and "findOne" and save it.

If "find" and "findOne" in a collection aren't enabled for "Public" or "Authenticated" users, then Strapi won't bother finding the id in the collection that the relation is referring to because you haven't allowed those users to access that data.

about 4 years ago · Juan Pablo Isaza Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda