Open bpedersen2 opened 1 month ago
@bpedersen2 thank you for testing this feature. In firefox, I'm not able to see the same error, but I can confirm that the form is not submitted. I will check soon in Chrome.
Based on the message that you posted, I found the following post that might help us in solving the issue: https://stackoverflow.com/questions/42053775/getting-error-form-submission-canceled-because-the-form-is-not-connected
And also the following: https://stackoverflow.com/questions/13001830/creating-and-submitting-a-form-with-javascript
I will work on it today or tomorrow, test it locally and create a PR if it solves the issue. This confirm to push to a higher priority reviewing and creating more FE E2E testing.
I would prefer to directly use the fetch api here. If you need form-data, see here: https://stackoverflow.com/questions/46640024/how-do-i-post-form-data-with-fetch-api
But I would make this configurable to either post json or formdata anyway.
I want to add some e2e testing, so I will implement one of the solutions proposed in the post.
First I will fix the form submission, than we can implement the call with fetch. It is unclear to me how to use fetch to make a POST request and show the results returned in a different window.
Summary
I tried to configure the new dataset actions (pointing download to the zipservice url)
Steps to Reproduce
configure a url pointing to the zip service
Current Behaviour
There is no request arriving at the zip service, and in the console one gets:
Expected Behaviour
The data arrive at the zip service
Extra Details
https://github.com/SciCatProject/frontend/pull/1528/files/2099d8a0cb8929078ae108a5bcc239b46a835d05#r1707136164