diff options
author | Matt Strapp <matt@mattstrapp.net> | 2022-04-01 17:50:13 +0200 |
---|---|---|
committer | Matt Strapp <matt@mattstrapp.net> | 2022-04-01 17:50:13 +0200 |
commit | 5717af872df070a50b9c27ccb21e2753339ae8fe (patch) | |
tree | 70dc16e57f4e4c552f92810eaf9d16c2dfaa56aa /src/public | |
parent | Bump @typescript-eslint/parser from 5.16.0 to 5.17.0 (#37) (diff) | |
download | ee4511w-web-5717af872df070a50b9c27ccb21e2753339ae8fe.tar ee4511w-web-5717af872df070a50b9c27ccb21e2753339ae8fe.tar.gz ee4511w-web-5717af872df070a50b9c27ccb21e2753339ae8fe.tar.bz2 ee4511w-web-5717af872df070a50b9c27ccb21e2753339ae8fe.tar.lz ee4511w-web-5717af872df070a50b9c27ccb21e2753339ae8fe.tar.xz ee4511w-web-5717af872df070a50b9c27ccb21e2753339ae8fe.tar.zst ee4511w-web-5717af872df070a50b9c27ccb21e2753339ae8fe.zip |
Attempt to add basic SAML
Signed-off-by: Matt Strapp <matt@mattstrapp.net>
Diffstat (limited to '')
-rw-r--r-- | src/public/js/form.js | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/public/js/form.js b/src/public/js/form.js index 1e9eaca..9823dcf 100644 --- a/src/public/js/form.js +++ b/src/public/js/form.js @@ -15,7 +15,7 @@ document.getElementById('upload').onsubmit = function () { document.getElementById('download-link').innerText = ''; // Make AJAX request let xhr = new XMLHttpRequest(); - xhr.open('POST', '/api/v1/upload'); + xhr.open('POST', '/api/v1/pendulum/upload'); let formData = new FormData(this); xhr.send(formData); xhr.onreadystatechange = function () { @@ -43,7 +43,7 @@ document.getElementById('upload').onsubmit = function () { // function actuate(file) { let xhr = new XMLHttpRequest(); - xhr.open('POST', '/api/v1/actuate'); + xhr.open('POST', '/api/v1/pendulum/actuate'); let data = { file: file.file, }; @@ -72,7 +72,10 @@ function createDownload(response) { const tempName = response.filename; const downloadName = response.name.split('.')[0]; const downloadLink = document.createElement('a'); - downloadLink.setAttribute('href', `/api/v1/download/?filename=${tempName}`); + downloadLink.setAttribute( + 'href', + `/api/v1/pendulum/download/?filename=${tempName}` + ); downloadLink.setAttribute('download', `${downloadName}.csv`); downloadLink.innerText = 'Download CSV of results here.'; document.getElementById('download-link').appendChild(downloadLink); |