|
|
@@ -110,8 +110,10 @@ public class PhotoAssetService {
|
|
|
// Asset asset = assetRepo.findById(photoAsset.getDestroyAssetId()).orElseThrow(new BusinessException("无藏品记录"));
|
|
|
// asset.setStatus(AssetStatus.NORMAL);
|
|
|
// assetRepo.saveAndFlush(asset);
|
|
|
- assetService.destroyWithoutTradeCode(photoAsset.getDestroyAssetId(), photoAsset
|
|
|
- .getUserId(), OperationSource.RAEX, null);
|
|
|
+ if (photoAsset.getDestroyAssetId() != null) {
|
|
|
+ assetService.destroyWithoutTradeCode(photoAsset.getDestroyAssetId(), photoAsset
|
|
|
+ .getUserId(), OperationSource.RAEX, null);
|
|
|
+ }
|
|
|
;
|
|
|
photoAssetRepo.save(photoAsset);
|
|
|
}
|