Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

168
Vistas
Uncaught (in promise) TypeError: $(...).submit(...).then is not a function when making an API call

I have a link which submits a POST request, and it was functioning well until I made some changes to my code, which as far as I'm aware have no bearing on this particular function. However, when I click my button I then receive the following error in console, and despite having looked into it, I'm not so sure how to rectify this, as it was working previously. I'd also like to understand the cause more.

Uncaught (in promise) TypeError: $(...).submit(...).then is not a function

In reference to this code:

$("#bugForm").submit((e) => {
        e.preventDefault()
        const input = document.getElementById('nameInput');
        bugInfo = {
          "name": `[${idTicket}] Bug report`,
          "story_type" : "Bug",
          "description": `+ ${data.ticket.brand.url}/agent/tickets/${idTicket}` + " \n" + `+ ${input.value}`,
        }
        reportBug(bugInfo).then(collapse.collapse('toggle'))
      }).then(() => {

        clearFields();
      })
    });
  });
});

HTML:

<form id="bugForm" method="POST">
      <textarea class="form-control" name="name" autocomplete="off" id="nameInput" rows="2"></textarea>
      <div id="sendbutton">
        <button type="submit" id="feedback-button" onclick="changeSecond();" class="btn btn-primary float-right">Send message</button>
      </div>
    </form>
about 4 years ago · Juan Pablo Isaza
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda