|
|
|
|
@ -47,33 +47,6 @@ function getVulnerabilityScrollContainer() {
|
|
|
|
|
return page ? page.querySelector('.page-content') : null;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function getExpandedVulnerabilityIds() {
|
|
|
|
|
const ids = [];
|
|
|
|
|
document.querySelectorAll('#vulnerabilities-list .vulnerability-content').forEach(function (el) {
|
|
|
|
|
if (el.style.display !== 'none') {
|
|
|
|
|
const id = (el.id || '').replace(/^content-/, '');
|
|
|
|
|
if (id) ids.push(id);
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
return ids;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function restoreExpandedVulnerabilityDetails(expandedIds) {
|
|
|
|
|
if (!expandedIds || !expandedIds.length) return;
|
|
|
|
|
expandedIds.forEach(function (id) {
|
|
|
|
|
const content = document.getElementById('content-' + id);
|
|
|
|
|
const icon = document.getElementById('expand-icon-' + id);
|
|
|
|
|
if (!content || content.style.display !== 'none') return;
|
|
|
|
|
content.style.display = 'block';
|
|
|
|
|
const row = content.closest('.vulnerability-table-detail');
|
|
|
|
|
if (row) row.hidden = false;
|
|
|
|
|
const trigger = document.getElementById('vulnerability-row-toggle-' + id);
|
|
|
|
|
if (trigger) trigger.setAttribute('aria-expanded', 'true');
|
|
|
|
|
if (icon) icon.style.transform = 'rotate(90deg)';
|
|
|
|
|
loadVulnerabilityRelatedFacts(id).catch(function (e) { console.warn(e); });
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function buildVulnerabilityStatusPicker(vuln) {
|
|
|
|
|
const current = vuln.status || 'open';
|
|
|
|
|
const id = escapeHtml(vuln.id);
|
|
|
|
|
@ -1304,13 +1277,9 @@ async function loadVulnerabilities(page = null, options = {}) {
|
|
|
|
|
const opts = options && typeof options === 'object' ? options : {};
|
|
|
|
|
const preserveScroll = !!opts.preserveScroll;
|
|
|
|
|
const silent = !!opts.silent;
|
|
|
|
|
let expandedIds = opts.expandedIds;
|
|
|
|
|
|
|
|
|
|
const scrollEl = preserveScroll ? getVulnerabilityScrollContainer() : null;
|
|
|
|
|
const scrollTop = scrollEl ? scrollEl.scrollTop : 0;
|
|
|
|
|
if (expandedIds === undefined && preserveScroll) {
|
|
|
|
|
expandedIds = getExpandedVulnerabilityIds();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
const listContainer = document.getElementById('vulnerabilities-list');
|
|
|
|
|
const hostOpenStates = preserveScroll
|
|
|
|
|
@ -1375,7 +1344,7 @@ async function loadVulnerabilities(page = null, options = {}) {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
renderVulnerabilities(vulnerabilities, {
|
|
|
|
|
view, expandedIds: expandedIds || [], hostOpenStates,
|
|
|
|
|
view, hostOpenStates,
|
|
|
|
|
preserveHostSelection: preserveScroll
|
|
|
|
|
});
|
|
|
|
|
renderVulnerabilityPagination();
|
|
|
|
|
@ -1419,18 +1388,15 @@ function renderVulnerabilities(vulnerabilities, renderOptions) {
|
|
|
|
|
const exactMatch = vulnerabilities.length === 1 && vulnerabilityFilters.id === vulnerabilities[0].id
|
|
|
|
|
? vulnerabilities[0].id
|
|
|
|
|
: null;
|
|
|
|
|
const expandedIds = exactMatch ? [exactMatch] : opts.expandedIds;
|
|
|
|
|
listContainer.innerHTML = renderVulnerabilityTable(vulnerabilities);
|
|
|
|
|
listContainer.innerHTML = renderVulnerabilityList(vulnerabilities);
|
|
|
|
|
initVulnerabilityStatusPickers(listContainer);
|
|
|
|
|
initVulnerabilityProjectBindSelects(listContainer);
|
|
|
|
|
if (typeof window.applyTranslations === 'function') {
|
|
|
|
|
window.applyTranslations(listContainer);
|
|
|
|
|
}
|
|
|
|
|
if (typeof rbacAfterDynamicRender === 'function') rbacAfterDynamicRender(listContainer);
|
|
|
|
|
if (exactMatch && vulnerabilities[0].summary_only && typeof openVulnerabilityInspector === 'function') {
|
|
|
|
|
if (exactMatch && typeof openVulnerabilityInspector === 'function') {
|
|
|
|
|
openVulnerabilityInspector(exactMatch);
|
|
|
|
|
} else {
|
|
|
|
|
restoreExpandedVulnerabilityDetails(expandedIds);
|
|
|
|
|
}
|
|
|
|
|
updateVulnerabilityListSummary();
|
|
|
|
|
}
|
|
|
|
|
@ -1448,7 +1414,7 @@ function updateVulnerabilityListSummary() {
|
|
|
|
|
if (!list || !toolbar) return;
|
|
|
|
|
const count = ['host','task'].includes(vulnerabilityView) && list.querySelector('.vulnerability-host-browser')
|
|
|
|
|
? new Set(vulnerabilityBrowserRows.map(vuln => vuln.id)).size
|
|
|
|
|
: list.querySelectorAll('.vulnerability-card, .vulnerability-table-item').length;
|
|
|
|
|
: list.querySelectorAll('.vulnerability-record-row').length;
|
|
|
|
|
document.getElementById('vulnerability-page-summary').textContent = count
|
|
|
|
|
? vulnT('vulnerabilityPage.pageFindings', { count }) : '';
|
|
|
|
|
}
|
|
|
|
|
@ -1547,7 +1513,7 @@ function renderVulnerabilityBrowser(vulnerabilities, opts) {
|
|
|
|
|
!Array.from(list.querySelectorAll('[data-host-key]')).some(el => el.dataset.hostKey === vulnerabilityBrowserSelection)) {
|
|
|
|
|
vulnerabilityBrowserSelection = '';
|
|
|
|
|
}
|
|
|
|
|
renderVulnerabilityBrowserTable(opts.expandedIds);
|
|
|
|
|
renderVulnerabilityBrowserTable();
|
|
|
|
|
if (activeSearch) {
|
|
|
|
|
search.focus({ preventScroll: true });
|
|
|
|
|
search.setSelectionRange(caret, caret);
|
|
|
|
|
@ -1586,7 +1552,7 @@ function renderVulnerabilityHostRiskDot(items) {
|
|
|
|
|
return highest ? `<span class="vulnerability-host-risk-dot severity-${highest}" title="${escapeAttr(vulnSeverityLabel(highest))}"></span>` : '';
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function renderVulnerabilityBrowserTable(expandedIds) {
|
|
|
|
|
function renderVulnerabilityBrowserTable() {
|
|
|
|
|
const selection = vulnerabilityBrowserSelection;
|
|
|
|
|
const items = getVisibleVulnerabilityBrowserItems();
|
|
|
|
|
document.querySelectorAll('#vulnerabilities-list [data-host-key]').forEach(option => {
|
|
|
|
|
@ -1613,100 +1579,41 @@ function renderVulnerabilityBrowserTable(expandedIds) {
|
|
|
|
|
).join('') + `<span class="vulnerability-group-pending">${escapeHtml(vulnT('vulnerabilityPage.groupPending', { count: pending }))}</span>`;
|
|
|
|
|
document.getElementById('vulnerability-host-export').disabled = items.length === 0;
|
|
|
|
|
const container = document.getElementById('vulnerability-host-table');
|
|
|
|
|
container.innerHTML = renderVulnerabilityTable(items);
|
|
|
|
|
container.innerHTML = renderVulnerabilityList(items);
|
|
|
|
|
initVulnerabilityStatusPickers(container);
|
|
|
|
|
initVulnerabilityProjectBindSelects(container);
|
|
|
|
|
if (typeof rbacAfterDynamicRender === 'function') rbacAfterDynamicRender(container);
|
|
|
|
|
const exact = items.find(vuln => vulnerabilityFilters.id === vuln.id);
|
|
|
|
|
if (exact?.summary_only && typeof openVulnerabilityInspector === 'function') openVulnerabilityInspector(exact.id);
|
|
|
|
|
else restoreExpandedVulnerabilityDetails(exact ? [exact.id] : expandedIds);
|
|
|
|
|
if (exact && typeof openVulnerabilityInspector === 'function') openVulnerabilityInspector(exact.id);
|
|
|
|
|
updateVulnerabilityListSummary();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function renderVulnerabilityTable(items) {
|
|
|
|
|
return items.length ? `<div class="vulnerability-table-scroll">
|
|
|
|
|
<table class="vulnerability-host-table">
|
|
|
|
|
<colgroup>
|
|
|
|
|
<col class="vulnerability-col-select"><col class="vulnerability-col-severity"><col>
|
|
|
|
|
<col class="vulnerability-col-target"><col class="vulnerability-col-status">
|
|
|
|
|
<col class="vulnerability-col-task"><col class="vulnerability-col-date"><col class="vulnerability-col-actions">
|
|
|
|
|
</colgroup>
|
|
|
|
|
<thead><tr>
|
|
|
|
|
<th scope="col" class="vulnerability-select-column">${escapeHtml(vulnT('vulnerabilityPage.selectColumn'))}</th>
|
|
|
|
|
${['tableSeverity', 'tableTitle', 'detailTarget', 'tableStatus', 'tableTask', 'tableDate', 'tableActions']
|
|
|
|
|
.map(key => '<th scope="col">' + escapeHtml(vulnT('vulnerabilityPage.' + key)) + '</th>').join('')}
|
|
|
|
|
</tr></thead>
|
|
|
|
|
${items.map(renderVulnerabilityTableItem).join('')}
|
|
|
|
|
</table></div>` : `<div class="empty-state">${escapeHtml(vulnT('vulnerabilityPage.noRecords'))}</div>`;
|
|
|
|
|
function renderVulnerabilityList(items) {
|
|
|
|
|
if (!items.length) {
|
|
|
|
|
return `<div class="empty-state">${escapeHtml(vulnT('vulnerabilityPage.noRecords'))}</div>`;
|
|
|
|
|
}
|
|
|
|
|
return `<ul class="vulnerability-record-list">${items.map(renderVulnerabilityListItem).join('')}</ul>`;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function renderVulnerabilityTableItem(vuln) {
|
|
|
|
|
function renderVulnerabilityListItem(vuln) {
|
|
|
|
|
const id = escapeAttr(vuln.id);
|
|
|
|
|
const jsID = escapeJsStringAttr(vuln.id);
|
|
|
|
|
const task = vuln.task_tag || vuln.task_id || vulnT('vulnerabilityPage.viewNoTask');
|
|
|
|
|
const targetHosts = Array.from(new Map((vuln.targets || []).map(target => [target.host,target])).values());
|
|
|
|
|
const created = new Date(vuln.created_at);
|
|
|
|
|
return `<tbody class="vulnerability-table-item" id="vulnerability-card-${id}" data-vuln-id="${id}">
|
|
|
|
|
<tr>
|
|
|
|
|
<td class="vulnerability-select-column">${typeof vulnerabilitySelectionInput === 'function' ? vulnerabilitySelectionInput(vuln) : ''}</td>
|
|
|
|
|
<td><span class="severity-badge severity-${escapeAttr(vuln.severity)}">${escapeHtml(vulnSeverityLabel(vuln.severity))}</span></td>
|
|
|
|
|
<td class="vulnerability-table-title">
|
|
|
|
|
<button type="button" id="vulnerability-row-toggle-${id}" class="vulnerability-row-toggle"
|
|
|
|
|
aria-expanded="false" aria-controls="content-${id}" onclick="${vuln.summary_only ? 'openVulnerabilityInspector' : 'toggleVulnerabilityDetails'}(${jsID})">
|
|
|
|
|
<span id="expand-icon-${id}" class="vulnerability-row-caret" aria-hidden="true">›</span>
|
|
|
|
|
<span class="vulnerability-table-name" title="${escapeAttr(vuln.title)}">${escapeHtml(vuln.title)}</span>
|
|
|
|
|
</button>
|
|
|
|
|
<p>${escapeHtml((vuln.description || '').slice(0, 160))}</p>
|
|
|
|
|
const summary = (vuln.description || vuln.target || '').replace(/\s+/g, ' ').trim();
|
|
|
|
|
return `<li class="vulnerability-record-row" id="vulnerability-card-${id}" data-vuln-id="${id}">
|
|
|
|
|
<span class="vulnerability-record-select">${typeof vulnerabilitySelectionInput === 'function' ? vulnerabilitySelectionInput(vuln) : ''}</span>
|
|
|
|
|
<span class="severity-badge severity-${escapeAttr(vuln.severity)}">${escapeHtml(vulnSeverityLabel(vuln.severity))}</span>
|
|
|
|
|
<button type="button" class="vulnerability-record-main" aria-haspopup="dialog" onclick="openVulnerabilityInspector(${jsID})">
|
|
|
|
|
<span class="vulnerability-record-title-line">
|
|
|
|
|
<span class="vulnerability-record-title" title="${escapeAttr(vuln.title)}">${escapeHtml(vuln.title)}</span>
|
|
|
|
|
${vuln.case_id ? `<span class="vulnerability-case-badge">${escapeHtml(vulnT('vulnerabilityPage.mergedRecord'))}</span>` : ''}
|
|
|
|
|
</td>
|
|
|
|
|
<td>${targetHosts.length ? targetHosts.slice(0,2).map(target =>
|
|
|
|
|
`<span class="vulnerability-table-target" title="${escapeAttr(target.raw)}">${escapeHtml(target.host)}</span>`).join('')
|
|
|
|
|
: `<span class="vulnerability-table-target" title="${escapeAttr(vuln.target || '')}">${escapeHtml(vuln.target_host || vuln.target || '—')}</span>`}
|
|
|
|
|
${(vuln.targets || []).length > 1 ? `<small>${escapeHtml(vulnT('vulnerabilityPage.targetCount', {count:vuln.targets.length}))}</small>` : ''}
|
|
|
|
|
</td>
|
|
|
|
|
<td>${buildVulnerabilityStatusPicker(vuln)}</td>
|
|
|
|
|
<td><span class="vulnerability-table-task" title="${escapeAttr(vuln.task_id || task)}">${escapeHtml(task)}</span></td>
|
|
|
|
|
<td class="vulnerability-table-date" title="${escapeAttr(created.toLocaleString(vulnDateLocale()))}">${escapeHtml(created.toLocaleString(vulnDateLocale(), {
|
|
|
|
|
month: '2-digit', day: '2-digit', hour: '2-digit', minute: '2-digit'
|
|
|
|
|
}))}</td>
|
|
|
|
|
<td><div class="vulnerability-table-actions">
|
|
|
|
|
<button type="button" class="btn-ghost" data-require-permission="vulnerability:write" onclick="openVulnerabilityRetest(${jsID})" ${vuln.conversation_id ? '' : 'disabled'}>${escapeHtml(vulnT('vulnerabilityRetest.button'))}</button>
|
|
|
|
|
<button type="button" class="btn-ghost" onclick="openVulnerabilityDownload(${jsID}, event)">${escapeHtml(vulnT('vulnerabilityPage.tableDownload'))}</button>
|
|
|
|
|
<button type="button" class="btn-ghost" data-require-permission="vulnerability:write" onclick="editVulnerability(${jsID})">${escapeHtml(vulnT('common.edit'))}</button>
|
|
|
|
|
<button type="button" class="btn-ghost" data-require-permission="vulnerability:delete" onclick="deleteVulnerability(${jsID})">${escapeHtml(vulnT('common.delete'))}</button>
|
|
|
|
|
</div></td>
|
|
|
|
|
</tr>
|
|
|
|
|
${vuln.summary_only ? '' : `<tr class="vulnerability-table-detail" hidden><td colspan="8">${renderVulnerabilityDetailsContent(vuln)}</td></tr>`}
|
|
|
|
|
</tbody>`;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function renderVulnerabilityDetailsContent(vuln) {
|
|
|
|
|
return `
|
|
|
|
|
<div class="vulnerability-content" id="content-${vuln.id}" style="display: none;">
|
|
|
|
|
${vuln.description ? `<div class="vulnerability-description">${escapeHtml(vuln.description)}</div>` : ''}
|
|
|
|
|
<div class="vulnerability-details">
|
|
|
|
|
${vulnDetailField(vulnT('vulnerabilityPage.detailVulnId'), vuln.id, true)}
|
|
|
|
|
${vulnDetailProjectField(vuln)}
|
|
|
|
|
${vuln.type ? vulnDetailField(vulnT('vulnerabilityPage.detailType'), vuln.type, false) : ''}
|
|
|
|
|
${vuln.target ? vulnDetailField(vulnT('vulnerabilityPage.detailTarget'), vuln.target, false) : ''}
|
|
|
|
|
${vulnDetailConversationField(vuln.conversation_id)}
|
|
|
|
|
${vuln.task_id ? vulnDetailField(vulnT('vulnerabilityPage.detailTaskId'), vuln.task_id, true) : ''}
|
|
|
|
|
${vuln.task_queue_id ? vulnDetailField(vulnT('vulnerabilityPage.detailTaskQueueId'), vuln.task_queue_id, true) : ''}
|
|
|
|
|
${vuln.conversation_tag ? vulnDetailField(vulnT('vulnerabilityPage.detailConversationTag'), vuln.conversation_tag, false) : ''}
|
|
|
|
|
${vuln.task_tag ? vulnDetailField(vulnT('vulnerabilityPage.detailTaskTag'), vuln.task_tag, false) : ''}
|
|
|
|
|
</div>
|
|
|
|
|
<div class="vulnerability-repro">
|
|
|
|
|
${vulnNarrativeSection(vulnT('vulnerabilityPage.detailPreconditions'), vuln.preconditions)}
|
|
|
|
|
${vulnNarrativeSection(vulnT('vulnerabilityPage.detailReproductionSteps'), vuln.reproduction_steps)}
|
|
|
|
|
${vulnNarrativeSection(vulnT('vulnerabilityPage.detailEvidence'), vuln.evidence, { code: true })}
|
|
|
|
|
${vulnNarrativeSection(vulnT('vulnerabilityPage.detailImpact'), vuln.impact)}
|
|
|
|
|
${vulnNarrativeSection(vulnT('vulnerabilityPage.detailRecommendation'), vuln.recommendation)}
|
|
|
|
|
${vulnNarrativeSection(vulnT('vulnerabilityPage.detailRetestNotes'), vuln.retest_notes)}
|
|
|
|
|
${vulnNarrativeSection(vulnT('vulnerabilityPage.detailRetestLog'), vuln.retest_log, { code: true })}
|
|
|
|
|
</div>
|
|
|
|
|
<div class="vulnerability-related-facts" id="vuln-related-facts-${escapeAttr(vuln.id)}" data-project-id="${escapeAttr(vuln.project_id || '')}" data-vuln-id="${escapeAttr(vuln.id)}" hidden></div>
|
|
|
|
|
</div>
|
|
|
|
|
`;
|
|
|
|
|
</span>
|
|
|
|
|
${summary ? `<span class="vulnerability-record-summary" title="${escapeAttr(summary)}">${escapeHtml(summary)}</span>` : ''}
|
|
|
|
|
</button>
|
|
|
|
|
<div class="vulnerability-record-actions">
|
|
|
|
|
${buildVulnerabilityStatusPicker(vuln)}
|
|
|
|
|
<button type="button" class="vulnerability-record-view" aria-haspopup="dialog" onclick="openVulnerabilityInspector(${jsID})">${escapeHtml(vulnT('vulnerabilityPage.viewFinding'))}</button>
|
|
|
|
|
</div>
|
|
|
|
|
</li>`;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// 渲染分页控件
|
|
|
|
|
@ -1977,7 +1884,6 @@ async function saveVulnerability() {
|
|
|
|
|
if (typeof refreshVulnerabilityInspector === 'function') refreshVulnerabilityInspector(currentVulnerabilityId);
|
|
|
|
|
const editedId = currentVulnerabilityId;
|
|
|
|
|
const isEdit = !!editedId;
|
|
|
|
|
const expandedIds = isEdit ? getExpandedVulnerabilityIds() : [];
|
|
|
|
|
|
|
|
|
|
closeVulnerabilityModal();
|
|
|
|
|
loadVulnerabilityStats();
|
|
|
|
|
@ -1994,7 +1900,7 @@ async function saveVulnerability() {
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
await loadVulnerabilities(null, { preserveScroll: true, silent: true, expandedIds: expandedIds });
|
|
|
|
|
await loadVulnerabilities(null, { preserveScroll: true, silent: true });
|
|
|
|
|
} catch (error) {
|
|
|
|
|
console.error('保存漏洞失败:', error);
|
|
|
|
|
alert(vulnT('vulnerabilityPage.saveFailed') + ': ' + error.message);
|
|
|
|
|
@ -2014,6 +1920,9 @@ async function deleteVulnerability(id) {
|
|
|
|
|
|
|
|
|
|
if (!response.ok) throw new Error(vulnT('vulnerabilityPage.deleteFailed'));
|
|
|
|
|
|
|
|
|
|
if (typeof vulnerabilityInspectorID !== 'undefined' && vulnerabilityInspectorID === id) {
|
|
|
|
|
closeAppModal('vulnerability-inspector');
|
|
|
|
|
}
|
|
|
|
|
loadVulnerabilityStats();
|
|
|
|
|
await removeVulnerabilityCard(id);
|
|
|
|
|
} catch (error) {
|
|
|
|
|
@ -2151,28 +2060,6 @@ async function saveVulnerabilityAlertSubscription() {
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// 切换漏洞详情展开/折叠
|
|
|
|
|
function toggleVulnerabilityDetails(id) {
|
|
|
|
|
const content = document.getElementById(`content-${id}`);
|
|
|
|
|
const icon = document.getElementById(`expand-icon-${id}`);
|
|
|
|
|
|
|
|
|
|
if (!content || !icon) return;
|
|
|
|
|
|
|
|
|
|
if (content.style.display === 'none') {
|
|
|
|
|
content.style.display = 'block';
|
|
|
|
|
icon.style.transform = 'rotate(90deg)';
|
|
|
|
|
loadVulnerabilityRelatedFacts(id).catch((e) => console.warn(e));
|
|
|
|
|
} else {
|
|
|
|
|
content.style.display = 'none';
|
|
|
|
|
icon.style.transform = 'rotate(0deg)';
|
|
|
|
|
}
|
|
|
|
|
const expanded = content.style.display !== 'none';
|
|
|
|
|
const row = content.closest('.vulnerability-table-detail');
|
|
|
|
|
if (row) row.hidden = !expanded;
|
|
|
|
|
const trigger = document.getElementById('vulnerability-row-toggle-' + id);
|
|
|
|
|
if (trigger) trigger.setAttribute('aria-expanded', String(expanded));
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/** 展开漏洞详情时加载关联项目事实 */
|
|
|
|
|
async function loadVulnerabilityRelatedFacts(vulnId) {
|
|
|
|
|
const el = document.getElementById(`vuln-related-facts-${vulnId}`);
|
|
|
|
|
@ -2658,11 +2545,7 @@ async function bindVulnerabilityProject(vulnId, projectId, silent) {
|
|
|
|
|
alert(vulnT('vulnerabilityPage.projectBindOk'));
|
|
|
|
|
}
|
|
|
|
|
loadVulnerabilityStats();
|
|
|
|
|
const expandedIds = getExpandedVulnerabilityIds();
|
|
|
|
|
if (!expandedIds.includes(vulnId)) {
|
|
|
|
|
expandedIds.push(vulnId);
|
|
|
|
|
}
|
|
|
|
|
await loadVulnerabilities(null, { preserveScroll: true, silent: true, expandedIds: expandedIds });
|
|
|
|
|
await loadVulnerabilities(null, { preserveScroll: true, silent: true });
|
|
|
|
|
} catch (error) {
|
|
|
|
|
console.error('绑定项目失败:', error);
|
|
|
|
|
alert(vulnT('vulnerabilityPage.projectBindFailed') + ': ' + error.message);
|
|
|
|
|
|