我这段代码有没有优化的可能?会return出来吗?
const handlePrint = async (type: string, num?: number) => {
....
if(type=='traOut'){
for(let i of selectedRows){
if(selectedRows[i].exeStatus !== '2'){
message.info('打印前提:该出库单执行状态为已关闭!');
return;
}
}
}
....
}