This commit is contained in:
mashuai 2024-04-03 15:26:11 +08:00
parent 9c8f44ff9f
commit 1f8fd7b7e1
1 changed files with 1 additions and 1 deletions

View File

@ -86,7 +86,7 @@ public class InventoryAndWarehousingServiceImpl implements InventoryAndWarehousi
}
} catch (Exception e) {
log.error("保存入库盘点异常:{}",e.getMessage());
// 添加事务回滚逻辑
// 添加事务回滚逻辑保证入库全部成功或者全部失败
TransactionAspectSupport.currentTransactionStatus().setRollbackOnly();
return AjaxResult.error(ExceptionEnum.SAVE_TO_DATABASE.getCode(), ExceptionEnum.SAVE_TO_DATABASE.getMsg());
}