Check everything
Check the exchange of data in the browser’s developer tools network tab. Make sure the right url is being sent and that the response contains the right data.
Second, inspect the data being returned. Does data
actually contain the object you’re expecting it to have?
Finally, verify that your updates should work by manually testing it in your browsers console. In other words, try something like:
document.getElementById("marketPrice").value = 5;
to see if the form has been updated. If it isn’t, then you may need to verify what the id
attributes are of the form you’re trying to update.