部分不需要打印具体的 异常

This commit is contained in:
2025-11-13 16:46:45 +08:00
parent 6ef2e022a6
commit 18cb6f8ce8

View File

@@ -84,6 +84,9 @@ public class ShopInfoServiceImpl extends ServiceImpl<ShopInfoMapper, ShopInfo> i
@Cacheable(key = "#id")
public ShopInfo getById(Serializable id) {
ShopInfo shopInfo = super.getById(id);
if(shopInfo == null){
throw new ApiNotPrintException("店铺不存在");
}
ShopConfig shopConfig = shopConfigService.getById(shopInfo.getId());
BeanUtil.copyProperties(shopConfig, shopInfo);
return shopInfo;