|
@@ -78,7 +78,7 @@ public class PartServiceImpl extends ServiceImpl<IPartMapper, Part> implements I
|
|
|
wrapper.eq(Part::getPartId,part.getPartId());
|
|
|
wrapper.setSql("part_stock = part_stock +" + part.getPartStock());
|
|
|
this.update(wrapper);
|
|
|
- partLogService.saveLog(part.getPartId(),part.getPartStock(),userId,0,null);
|
|
|
+ partLogService.saveLog(part.getPartId(),part.getPartStock(),userId,0,null,null);
|
|
|
}
|
|
|
|
|
|
@Override
|
|
@@ -93,24 +93,24 @@ public class PartServiceImpl extends ServiceImpl<IPartMapper, Part> implements I
|
|
|
|
|
|
}
|
|
|
@Override
|
|
|
- public void outStock(Integer partId, Integer count,Long userId,String repairId) {
|
|
|
+ public void outStock(Integer partId, Integer count,Long userId,String repairId,Integer priceListId) {
|
|
|
LambdaUpdateWrapper<Part> wrapper = new LambdaUpdateWrapper<>();
|
|
|
wrapper.eq(Part::getPartId,partId);
|
|
|
wrapper.setSql("part_stock = part_stock -" + count);
|
|
|
this.update(wrapper);
|
|
|
- partLogService.saveLog(partId,count,userId,1,repairId);
|
|
|
+ partLogService.saveLog(partId,count,userId,1,repairId,priceListId);
|
|
|
|
|
|
}
|
|
|
|
|
|
@Override
|
|
|
- public void recovery(Integer partId, Integer partCount, Long userId, String repairId,Integer status) {
|
|
|
+ public void recovery(Integer partId, Integer partCount, Long userId, String repairId,Integer status,Integer priceListId) {
|
|
|
if(status.equals(RepairStatusEnum.TO_BE_CANCELED_RECOVERED.status())){
|
|
|
LambdaUpdateWrapper<Part> wrapper = new LambdaUpdateWrapper<>();
|
|
|
wrapper.eq(Part::getPartId,partId);
|
|
|
wrapper.setSql("part_stock = part_stock +" +partCount);
|
|
|
this.update(wrapper);
|
|
|
}
|
|
|
- partLogService.saveLog(partId,partCount,userId,2,repairId);
|
|
|
+ partLogService.saveLog(partId,partCount,userId,2,repairId,priceListId);
|
|
|
|
|
|
}
|
|
|
|