upload stocks and crypto logos
This commit is contained in:
parent
155d085a4d
commit
cb44fae63e
@ -3348,3 +3348,44 @@ function scanNetworks() {
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
// UPLOAD CUSTOM STOCK LOGO
|
||||
function uploadStockLogo() {
|
||||
const fileInput_stocks = document.getElementById("stocks-logo-upload-browse");
|
||||
const stock_file = fileInput_stocks.files[0];
|
||||
const stock_upload_msg = document.getElementById("stocklogoupload");
|
||||
|
||||
const formData_stocks = new FormData();
|
||||
formData_stocks.append('file', stock_file)
|
||||
fetch('/upload_stocks', {
|
||||
method: 'POST',
|
||||
body: formData_stocks
|
||||
})
|
||||
stock_upload_msg.style.display = "block";
|
||||
setTimeout(function hideElement() {
|
||||
stock_upload_msg.style.display = "none";
|
||||
}, 5000);
|
||||
fileInput_stocks.value = "";
|
||||
}
|
||||
|
||||
|
||||
// UPLOAD CUSTOM CRYPTO LOGO
|
||||
function uploadCryptoLogo() {
|
||||
const fileInput_crypto = document.getElementById("crypto-logo-upload-browse");
|
||||
const crypto_file = fileInput_crypto.files[0];
|
||||
const crypto_upload_msg = document.getElementById("cryptologoupload");
|
||||
|
||||
const formData_crypto = new FormData();
|
||||
formData_crypto.append('file', crypto_file);
|
||||
fetch('/upload_crypto', {
|
||||
method: 'POST',
|
||||
body: formData_crypto
|
||||
})
|
||||
crypto_upload_msg.style.display = "block";
|
||||
setTimeout(function hideElement() {
|
||||
crypto_upload_msg.style.display = "none";
|
||||
}, 5000);
|
||||
fileInput_crypto.value = "";
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user