| | |
| | | if (null == client){ |
| | | return R.error("客户不存在"); |
| | | } |
| | | order.setCstmr(client.getCode()); |
| | | order.setCstmrName(client.getName()); |
| | | // 修改主档 |
| | | if (!param.getDocType().equals(order.getDocType()) || !param.getOrderTime().equals(order.getOrderTime())) { |
| | | order.setCstmr(client.getCode()); |
| | | order.setCstmrName(client.getName()); |
| | | |
| | | order.setDocType(param.getDocType()); |
| | | order.setOrderTime(param.getOrderTime()); |
| | | order.setUpdateBy(userId); |
| | | order.setUpdateTime(now); |
| | | if (!orderService.updateById(order)) { |
| | | throw new CoolException("修改订单类型失败"); |
| | | } |
| | | |
| | | } |
| | | order.setUpdateBy(userId); |
| | | order.setUpdateTime(now); |
| | | if (!orderService.updateById(order)) { |
| | | throw new CoolException("修改订单类型失败"); |
| | | } |
| | | |
| | | // 修改明细档 |
| | | // List<OrderDetl> orderDetls = orderDetlService.selectByOrderId(order.getId()); |
| | | // 1.清空明细档 |