diff --git a/dl-module-base/src/main/java/cn/iocoder/yudao/module/order/controller/admin/RepairOrderInfoController.java b/dl-module-base/src/main/java/cn/iocoder/yudao/module/order/controller/admin/RepairOrderInfoController.java index 9e2cbbf4..dde61feb 100644 --- a/dl-module-base/src/main/java/cn/iocoder/yudao/module/order/controller/admin/RepairOrderInfoController.java +++ b/dl-module-base/src/main/java/cn/iocoder/yudao/module/order/controller/admin/RepairOrderInfoController.java @@ -111,6 +111,6 @@ public class RepairOrderInfoController { @GetMapping("/toPay") @Operation(summary = "PC支付按钮") public CommonResult toPay(@RequestParam("id")String id) throws IOException, NoSuchAlgorithmException, SignatureException, InvalidKeyException { - return success(repairOrderInfoService.payTransactions(id)); + return success(repairOrderInfoService.payTransactionsCode(id)); } } \ No newline at end of file diff --git a/dl-module-repair/src/main/java/cn/iocoder/yudao/module/tickets/service/impl/DlRepairTicketsServiceImpl.java b/dl-module-repair/src/main/java/cn/iocoder/yudao/module/tickets/service/impl/DlRepairTicketsServiceImpl.java index 31d23f15..5ba05b08 100644 --- a/dl-module-repair/src/main/java/cn/iocoder/yudao/module/tickets/service/impl/DlRepairTicketsServiceImpl.java +++ b/dl-module-repair/src/main/java/cn/iocoder/yudao/module/tickets/service/impl/DlRepairTicketsServiceImpl.java @@ -743,11 +743,11 @@ public class DlRepairTicketsServiceImpl extends ServiceImpl stringObjectMap = repairOrderInfoService.payTransactions(orderInfo.getId()); - payUrl = (String) stringObjectMap.get("prepay_id"); + Map stringObjectMap = repairOrderInfoService.payTransactionsCode(orderInfo.getId()); + payUrl = (String) stringObjectMap.get("code_url"); // 这个地方可能报错,报错就不生成二维码了,保证工单是能出来的 // 生成收款二维码 int width = 100, height = 100; @@ -1357,6 +1357,16 @@ public class DlRepairTicketsServiceImpl extends ServiceImpl().eq(RepairOrderInfo::getGoodsId, ticketId)); + RepairOrderInfo newOrderInfo = new RepairOrderInfo(); + newOrderInfo.setId(orderInfo.getId()); + // 更新商品原价和实付金额 + newOrderInfo.setGoodsPrice(tickets.getTotalPrice()); + newOrderInfo.setPayMoney(tickets.getTotalPrice()); + repairOrderInfoService.updateById(newOrderInfo); + return baseMapper.updateById(tickets) > 0; }