tony.cheng
2026-03-04 9167ea7dca015c7ff1f35fa7eb63161fe10eac7b
web-app/src/components/dashboard/TabContainer.jsx
@@ -1394,14 +1394,11 @@
    if (!caseId) return;
    setActionLoading(prev => ({ ...prev, download: true }));
    try {
      // 调用API获取协议内容
      // 调用API获取PDF文件流
      const response = await MediationAgreementAPIService.downloadAgreement(caseId);
      
      if (response?.data?.agreeContent) {
        const agreementContent = response.data.agreeContent;
        // 创建Blob对象
        const blob = new Blob([agreementContent], {
      // 创建Blob对象(PDF格式)
      const blob = new Blob([response.data], {
          type: 'application/pdf' 
        });
        
@@ -1420,9 +1417,6 @@
        window.URL.revokeObjectURL(url);
        
        message.success('协议下载成功!');
      } else {
        message.error('未获取到协议内容');
      }
    } catch (err) {
      console.error('下载协议失败:', err);
      message.error('下载协议失败,请稍后重试');