|
|
|
@ -1653,11 +1653,8 @@ |
|
|
|
|
|
|
|
<!-- 状态导航栏 - 供应商 --> |
|
|
|
<div class="status-nav supplier-status-nav"> |
|
|
|
<button class="status-btn active" data-status="underreview">审核中</button> |
|
|
|
<button class="status-btn" data-status="reviewfailed">审核失败</button> |
|
|
|
<button class="status-btn" data-status="approved">审核通过</button> |
|
|
|
<button class="status-btn" data-status="incooperation">合作中</button> |
|
|
|
<button class="status-btn" data-status="notcooperative">未合作</button> |
|
|
|
<button class="status-btn active" data-status="underreview">未跟进</button> |
|
|
|
<button class="status-btn" data-status="approved">已跟进</button> |
|
|
|
</div> |
|
|
|
|
|
|
|
<!-- 总数显示 --> |
|
|
|
@ -2002,6 +1999,13 @@ |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
// 跟进按钮 |
|
|
|
if (e.target.classList.contains('btn-default') && e.target.closest('.action-buttons')) { |
|
|
|
const id = e.target.getAttribute('data-id'); |
|
|
|
if (id && e.target.textContent.trim() === '跟进') { |
|
|
|
showFollowupModal(id); |
|
|
|
} |
|
|
|
} |
|
|
|
}); |
|
|
|
} |
|
|
|
|
|
|
|
@ -2440,37 +2444,37 @@ |
|
|
|
<!-- 操作按钮 --> |
|
|
|
<div class="action-buttons"> |
|
|
|
${canReview ? ` |
|
|
|
<button class="btn btn-default" data-id="${id}" onclick="showFollowupModal('${id}')"> |
|
|
|
<button class="btn btn-default" data-id="${id}"> |
|
|
|
跟进 |
|
|
|
</button> |
|
|
|
<button class="btn btn-primary" data-id="${id}" onclick="showSupplierApproveModal('${id}')"> |
|
|
|
<button class="btn btn-primary" data-id="${id}"> |
|
|
|
通过 |
|
|
|
</button> |
|
|
|
<button class="btn btn-danger" data-id="${id}" onclick="showSupplierRejectModal('${id}')"> |
|
|
|
<button class="btn btn-danger" data-id="${id}"> |
|
|
|
拒绝 |
|
|
|
</button> |
|
|
|
` : canTerminate ? ` |
|
|
|
<button class="btn btn-default" data-id="${id}" onclick="showFollowupModal('${id}')"> |
|
|
|
<button class="btn btn-default" data-id="${id}"> |
|
|
|
跟进 |
|
|
|
</button> |
|
|
|
<button class="btn btn-danger" data-id="${id}" onclick="showTerminateModal('${id}')"> |
|
|
|
<button class="btn btn-danger" data-id="${id}"> |
|
|
|
终止合作 |
|
|
|
</button> |
|
|
|
<div class="audit-time"> |
|
|
|
审核时间:${formatTime(auditTime)} |
|
|
|
</div> |
|
|
|
` : canCooperate ? ` |
|
|
|
<button class="btn btn-default" data-id="${id}" onclick="showFollowupModal('${id}')"> |
|
|
|
<button class="btn btn-default" data-id="${id}"> |
|
|
|
跟进 |
|
|
|
</button> |
|
|
|
<button class="btn btn-primary" data-id="${id}" onclick="confirmSupplierToCooperation('${id}')"> |
|
|
|
<button class="btn btn-primary" data-id="${id}"> |
|
|
|
开始合作 |
|
|
|
</button> |
|
|
|
<div class="audit-time"> |
|
|
|
审核时间:${formatTime(auditTime)} |
|
|
|
</div> |
|
|
|
` : ` |
|
|
|
<button class="btn btn-default" data-id="${id}" onclick="showFollowupModal('${id}')"> |
|
|
|
<button class="btn btn-default" data-id="${id}"> |
|
|
|
跟进 |
|
|
|
</button> |
|
|
|
<div class="audit-time"> |
|
|
|
@ -2567,6 +2571,20 @@ |
|
|
|
// 显示供应商通过确认弹窗 |
|
|
|
function showSupplierApproveModal(supplierId) { |
|
|
|
currentSupplierId = supplierId; |
|
|
|
|
|
|
|
// 检查供应商是否有跟进信息 |
|
|
|
const supplyItem = document.querySelector(`.supply-item[data-id="${supplierId}"]`); |
|
|
|
if (supplyItem) { |
|
|
|
const hasFollowup = supplyItem.querySelector('.supply-followup') !== null; |
|
|
|
|
|
|
|
// 如果没有跟进信息,提示用户需要先跟进并直接弹出跟进弹窗 |
|
|
|
if (!hasFollowup) { |
|
|
|
alert('该供应商尚未跟进,需要先添加跟进信息才能通过!'); |
|
|
|
showFollowupModal(supplierId); |
|
|
|
return; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
approveModalEl.style.display = 'flex'; |
|
|
|
} |
|
|
|
|
|
|
|
|