fix
parent
b9936cf368
commit
eeb34c722a
|
|
@ -99,6 +99,12 @@ const ContractContent = ({ readOnly, ...props }) => {
|
|||
try {
|
||||
const values = await form.validateFields();
|
||||
const { contractStartDate, contractEndDate, ...rest } = values;
|
||||
// 检查是否有文件正在上传中
|
||||
const fileList = rest.scanFileUrl || [];
|
||||
if (fileList.some((f) => f.status === "uploading")) {
|
||||
message.warning("文件上传中,请稍后再保存");
|
||||
return;
|
||||
}
|
||||
const res = await evalContractSave({
|
||||
...rest,
|
||||
projectId,
|
||||
|
|
|
|||
|
|
@ -90,6 +90,12 @@ const RiskAnalysisContent = ({ readOnly, ...props }) => {
|
|||
const values = await form.validateFields();
|
||||
|
||||
const { analysisDate, ...rest } = values;
|
||||
// 检查是否有文件正在上传中
|
||||
const fileList = rest.riskFileUrl || [];
|
||||
if (fileList.some((f) => f.status === "uploading")) {
|
||||
message.warning("文件上传中,请稍后再保存");
|
||||
return;
|
||||
}
|
||||
// if (!rest.participants?.length) {
|
||||
// message.warning("请选择风险分析人员");
|
||||
// return;
|
||||
|
|
|
|||
|
|
@ -21,7 +21,7 @@ const STAGES = [
|
|||
|
||||
const downloadTemplate = async () => {
|
||||
try {
|
||||
const res = await fetch("https://test-dragon-yf-pub.oss-cn-hangzhou.aliyuncs.com/jjb/6a6726510dc57d9450a911be.docx");
|
||||
const res = await fetch("https://test-dragon-yf-pub.oss-cn-hangzhou.aliyuncs.com/jjb/6a6bff3ee4b021a75404adfb.docx");
|
||||
const blob = await res.blob();
|
||||
const url = URL.createObjectURL(blob);
|
||||
const a = document.createElement("a");
|
||||
|
|
@ -263,6 +263,15 @@ const SurveyContent = ({ readOnly, ...props }) => {
|
|||
|
||||
const handleSave = async () => {
|
||||
const values = form.getFieldsValue();
|
||||
// 检查是否有文件正在上传中
|
||||
const hasUploading = STAGES.some((s) => {
|
||||
const fileList = values[s.key] || [];
|
||||
return fileList.some((f) => f.status === "uploading");
|
||||
});
|
||||
if (hasUploading) {
|
||||
message.warning("文件上传中,请稍后再保存");
|
||||
return;
|
||||
}
|
||||
const payload = [];
|
||||
for (const s of STAGES) {
|
||||
const fileList = values[s.key] || [];
|
||||
|
|
|
|||
Loading…
Reference in New Issue