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

218
Visualizações
How can I update strapi components that are within a collection type?

I’m working on a project that requires the user to update their address to their organization from a front end form (a long with a number of other things). All of the updates work to the organization collection type I have, but it’s when I try and update to Locations component I have, that I can’t seem to get it to POST.

Is there something specific I need to do for the strapi query within the controller that just isn’t working? It pulls the current field from the component no problem, but just won’t save the updates.

Everything is working but the streetAddress one. Nothing errors out, it just updates all but that. Any help would be greatly appreciated.

Here’s my current query.

 strapi.query('organization').update({ id }, {
      name: ctx.request.body.name,
      phone: ctx.request.body.phone,
      email: ctx.request.body.email,
      webSite: ctx.request.body.webSite,
      streetAddress: ctx.request.body.locations[0].streetAddress,
    });
about 4 years ago · Juan Pablo Isaza
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