|
|
@@ -102,13 +102,15 @@ public class BCurrencyServiceImpl extends ServiceImpl<CurrencyMapper, BCurrency>
|
|
|
List<BCurExrate> bCurExrateListAdd = new ArrayList<>();
|
|
|
List<BCurExrate> bCurExrateListUpdate = new ArrayList<>();
|
|
|
for (BCurExrate item : bCurrency.getCurExrateList()) {
|
|
|
- item.setType(bCurrency.getParitiesType());
|
|
|
+ if (item.getId() == null){
|
|
|
+ item.setType(bCurrency.getParitiesType());
|
|
|
+ }
|
|
|
item.setCode(bCurrency.getCode());
|
|
|
BCurExrate bCurExrate = bCurExrateService.getOne(new LambdaQueryWrapper<BCurExrate>()
|
|
|
.eq(BCurExrate::getExrateYear, item.getExrateYear())
|
|
|
.eq(ObjectUtils.isNotNull(item.getExrateMonth()), BCurExrate::getExrateMonth, item.getExrateMonth())
|
|
|
.eq(ObjectUtils.isNotNull(item.getExrateDay()), BCurExrate::getExrateDay, item.getExrateDay())
|
|
|
- .eq(BCurExrate::getType, bCurrency.getParitiesType())
|
|
|
+ .eq(BCurExrate::getType, item.getType())
|
|
|
.eq(BCurExrate::getCode, item.getCode())
|
|
|
);
|
|
|
if (bCurExrate != null) {
|