web: update java issues
This commit is contained in:
@@ -84,7 +84,7 @@ function initializeEventListeners() {
|
|||||||
document.getElementById('custom-scan-form').addEventListener('submit', handleCustomScan);
|
document.getElementById('custom-scan-form').addEventListener('submit', handleCustomScan);
|
||||||
|
|
||||||
// Custom directory input auto-formatting
|
// Custom directory input auto-formatting
|
||||||
document.getElementById('custom-directory').addEventListener('input', handleDirectoryFormatting);
|
document.getElementById('scan-path').addEventListener('input', handleDirectoryFormatting);
|
||||||
}
|
}
|
||||||
|
|
||||||
// API calls
|
// API calls
|
||||||
@@ -1444,16 +1444,16 @@ async function handleManualScan(event) {
|
|||||||
async function handleCustomScan(event) {
|
async function handleCustomScan(event) {
|
||||||
event.preventDefault();
|
event.preventDefault();
|
||||||
|
|
||||||
const customDirectory = document.getElementById('custom-directory').value.trim();
|
const customDirectory = document.getElementById('scan-path').value.trim();
|
||||||
const customScanMode = document.getElementById('custom-scan-mode').value;
|
const customScanType = document.getElementById('custom-scan-type').value;
|
||||||
|
|
||||||
if (!customDirectory) {
|
if (!customDirectory) {
|
||||||
showToast('Please enter a directory path', 'warning');
|
showToast('Please enter a directory path', 'warning');
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!customScanMode) {
|
if (!customScanType) {
|
||||||
showToast('Please select a scan mode', 'warning');
|
showToast('Please select a scan type', 'warning');
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1465,7 +1465,7 @@ async function handleCustomScan(event) {
|
|||||||
method: 'POST',
|
method: 'POST',
|
||||||
body: JSON.stringify({
|
body: JSON.stringify({
|
||||||
directory: customDirectory,
|
directory: customDirectory,
|
||||||
scan_mode: customScanMode
|
scan_type: customScanType
|
||||||
})
|
})
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user