|
@@ -124,7 +124,7 @@ public class QyRecordInfoServiceImpl extends ServiceImpl<QyRecordInfoMapper, QyR
|
|
|
qyRecardBodyAddParams.stream().forEach(qyRecardBodyAddParam -> {
|
|
|
qyRecardBodyAddParam.setQyRecordInfoId(qyRecordInfo.getId());
|
|
|
QyRecardBody qyRecardBody = BeanUtil.toBean(qyRecardBodyAddParam, QyRecardBody.class);
|
|
|
- String productNum = BusinessIdGenerator.generateBusinessIdForProductNum(i.get());
|
|
|
+ String productNum = BusinessIdGenerator.generateBusinessIdForProductNum(i.incrementAndGet());
|
|
|
qyRecardBody.setQyRecordInfoId(qyRecordInfo.getId());
|
|
|
qyRecardBody.setProductNum(productNum);
|
|
|
qyRecardBodyService.save(qyRecardBody);
|
|
@@ -210,11 +210,11 @@ public class QyRecordInfoServiceImpl extends ServiceImpl<QyRecordInfoMapper, QyR
|
|
|
//料件信息
|
|
|
List<QyRecardBodyEditParam> bodyAddParams = qyRecordInfoEditParam.getQyRecardBodyEditParams();
|
|
|
if (CollectionUtil.isNotEmpty(bodyAddParams)){
|
|
|
- AtomicInteger i = new AtomicInteger();
|
|
|
+ AtomicInteger i = new AtomicInteger(0);
|
|
|
bodyAddParams.stream().forEach(qyRecardBodyAddParam -> {
|
|
|
qyRecardBodyAddParam.setQyRecordInfoId(qyRecordInfo.getId());
|
|
|
QyRecardBody qyRecardBody = BeanUtil.toBean(qyRecardBodyAddParam, QyRecardBody.class);
|
|
|
- String productNum = BusinessIdGenerator.generateBusinessIdForProductNum(i.get());
|
|
|
+ String productNum = BusinessIdGenerator.generateBusinessIdForProductNum(i.incrementAndGet());
|
|
|
qyRecardBody.setQyRecordInfoId(qyRecordInfo.getId());
|
|
|
qyRecardBody.setProductNum(productNum);
|
|
|
qyRecardBody.setId(null);
|