Merge remote-tracking branch 'origin/main'
This commit is contained in:
commit
0a90c406b3
@ -673,16 +673,36 @@ const handleSelectedProjectOrder = (arr: ProjectOrderVO[]) => {
|
||||
};
|
||||
const parentMethod = async () => {
|
||||
// 检查是否超过要求设计日期
|
||||
const isOverdue = dataList.value.projectOrderSubs.some(sub => {
|
||||
|
||||
let overdueTime = null; // 初始化变量
|
||||
let projectName = null; // 初始化变量
|
||||
const isOverdue = dataList.value.projectOrderSubs.some(sub => {
|
||||
if (sub.changeEndTime) {
|
||||
const isOverdueSub = sub.blankDate > sub.changeEndTime ||
|
||||
sub.twoDimDate > sub.changeEndTime ||
|
||||
sub.threeDimDate > sub.changeEndTime;
|
||||
|
||||
// 如果当前 sub 是超期的,将 sub.changeEndTime 赋值给 overdueTime
|
||||
if (isOverdueSub) {
|
||||
overdueTime = sub.changeEndTime;
|
||||
projectName = sub.projectSubName;
|
||||
}
|
||||
|
||||
return isOverdueSub;
|
||||
}
|
||||
return false;
|
||||
});
|
||||
|
||||
/* const isOverdue = dataList.value.projectOrderSubs.some(sub => {
|
||||
if (sub.changeEndTime) {
|
||||
return sub.blankDate > sub.changeEndTime ||
|
||||
sub.twoDimDate > sub.changeEndTime ||
|
||||
sub.threeDimDate > sub.changeEndTime;
|
||||
}
|
||||
return false;
|
||||
});
|
||||
}); */
|
||||
if (isOverdue) {
|
||||
message.error("本次插活已经超过要求设计结束日期,无法插活");
|
||||
message.error(projectName+",超过要求设计结束日期-"+formatDate(overdueTime,'YYYY-MM-DD')+",不允许插活");
|
||||
return; // 如果超过日期,直接返回,不执行后续代码
|
||||
}
|
||||
dialogVisible.value = false;
|
||||
|
Loading…
Reference in New Issue
Block a user