|
@@ -52,12 +52,13 @@ public class LogisticsAmountServiceImpl extends ServiceImpl<LogisticsAmountMappe
|
|
|
|
|
|
@DSTransactional
|
|
|
@Override
|
|
|
- public void saveOrEditList(List<LogisticsAmountDto> list) {
|
|
|
- for (LogisticsAmountDto dto : list) {
|
|
|
- Assert.notEmpty(dto.getLogisticsCompanyId(), "物流公司不能为空!");
|
|
|
- Assert.notEmpty(dto.getYear(), "年份不能为空!");
|
|
|
- this.saveOrUpdate(dto);
|
|
|
+ public void saveOrEditList(LogisticsAmountDto dto) {
|
|
|
+ List<LogisticsAmount> logisticsAmountList = dto.getLogisticsAmountList();
|
|
|
+ for (LogisticsAmount logisticsAmount : logisticsAmountList) {
|
|
|
+ Assert.notEmpty(logisticsAmount.getLogisticsCompanyId(), "物流公司不能为空!");
|
|
|
+ Assert.notEmpty(logisticsAmount.getYear(), "年份不能为空!");
|
|
|
}
|
|
|
+ this.editLinked(logisticsAmountList, LogisticsAmount::getLogisticsCompanyId, dto.getLogisticsCompanyId());
|
|
|
}
|
|
|
|
|
|
}
|