支付 app、商户,删除时,需要校验关联数据

This commit is contained in:
zhijiantianya@gmail.com 2021-12-27 11:40:07 +08:00
parent e8368bb7fd
commit 054c237b1f
2 changed files with 2 additions and 0 deletions

View File

@ -61,6 +61,7 @@ public class PayAppServiceImpl implements PayAppService {
public void deleteApp(Long id) {
// 校验存在
this.validateAppExists(id);
// TODO aquan校验是否存在进行中的支付单退款单如果是则不允许删除
// 删除
appMapper.deleteById(id);
}

View File

@ -57,6 +57,7 @@ public class PayMerchantServiceImpl implements PayMerchantService {
public void deleteMerchant(Long id) {
// 校验存在
this.validateMerchantExists(id);
// TODO @aquan需要校验 PayApp 是否都在如果在的情况下不允许删除
// 删除
merchantMapper.deleteById(id);
}