| | |
| | | |
| | | import com.baomidou.mybatisplus.mapper.EntityWrapper; |
| | | import com.core.common.Cools; |
| | | import com.core.common.DateUtils; |
| | | import com.core.common.SnowflakeIdWorker; |
| | | import com.core.exception.CoolException; |
| | | import com.zy.asrs.entity.*; |
| | |
| | | now, // 修改时间 |
| | | null // 备注 |
| | | ); |
| | | order.setShipCode(param.getQuality()); |
| | | if (!orderService.insert(order)) { |
| | | throw new CoolException("生成单据主档失败,请联系管理员"); |
| | | } |
| | | // 单据明细档 |
| | | List<DetlDto> list = new ArrayList<>(); |
| | | List<DetlDto> orderDetails = param.getOrderDetails(); |
| | | List<DetlDto> orderDetails = param.getDetails(); |
| | | for (DetlDto detail : orderDetails) { |
| | | DetlDto dto = new DetlDto(detail.getMatnr(), detail.getBatch(), detail.getAnfme(),detail.getFromOrderNo() |
| | | , detail.getMark(),detail.getCustomer(),detail.getSuppName(),detail.getTemp1(),detail.getTemp2(),detail.getTemp3(),detail.getTemp4()); |
| | |
| | | now, // 修改时间 |
| | | null // 备注 |
| | | ); |
| | | order.setShipCode(param.getQuality()); |
| | | if (!orderService.insert(order)) { |
| | | throw new CoolException("生成单据主档失败,请联系管理员"); |
| | | } |
| | | // 单据明细档 |
| | | List<DetlDto> list = new ArrayList<>(); |
| | | List<DetlDto> orderDetails = param.getOrderDetails(); |
| | | List<DetlDto> orderDetails = param.getDetails(); |
| | | for (DetlDto detail : orderDetails) { |
| | | DetlDto dto = new DetlDto(detail.getMatnr(), detail.getBatch(), detail.getAnfme(),detail.getFromOrderNo() |
| | | , detail.getMark(),detail.getCustomer(),detail.getSuppName(),detail.getTemp1(),detail.getTemp2(),detail.getTemp3(),detail.getTemp4()); |
| | | dto.setTemp1(param.getQuality()); |
| | | if (DetlDto.has(list, dto)) { |
| | | DetlDto detlDto = DetlDto.find(list, dto.getMatnr(), dto.getBatch()); |
| | | assert detlDto != null; |