From 1442f149019ee0590389abd7a88a79c4d9b59034 Mon Sep 17 00:00:00 2001 From: 无关风月 <443237572@qq.com> Date: 星期二, 27 五月 2025 18:23:34 +0800 Subject: [PATCH] bug修改 --- ruoyi-service/ruoyi-user/src/main/java/com/ruoyi/user/controller/OrderController.java | 34 +++++++--------------------------- 1 files changed, 7 insertions(+), 27 deletions(-) diff --git a/ruoyi-service/ruoyi-user/src/main/java/com/ruoyi/user/controller/OrderController.java b/ruoyi-service/ruoyi-user/src/main/java/com/ruoyi/user/controller/OrderController.java index dde572e..4acf1bf 100644 --- a/ruoyi-service/ruoyi-user/src/main/java/com/ruoyi/user/controller/OrderController.java +++ b/ruoyi-service/ruoyi-user/src/main/java/com/ruoyi/user/controller/OrderController.java @@ -173,38 +173,18 @@ */ @GetMapping("/allowanceMoney") @ApiOperation(value = "补充订单津贴金额", tags = {"用户端-订单"}) - public R<Object> allowanceMoney(@RequestParam("orderId") String orderId, @RequestParam("prizeId") String prizeId) { + public R<Object> allowanceMoney(@RequestParam("orderId") String orderId, + @RequestParam("prizeId") String prizeId, + @RequestParam("serveId") String serveId) { Prize data = adminClient.prizeDetail(prizeId).getData(); if (null == data) { return R.fail(adminClient.prizeDetail(prizeId).getMsg()); } String prizeMoney; - if (data.getPrizeName().contains(Constants.SUBSIDY_MONEY)) { - prizeMoney = data.getPrizeName().substring(Constants.ONE); - } else { - prizeMoney = "0"; - } - return R.ok(orderClient.supplementAllowance(orderId, prizeMoney).getData()); - } - - /** - * 分享获取津贴 - * - * @return 奖品列表 - */ - @GetMapping("/shareAllowanceMoney") - @ApiOperation(value = "分享获取津贴", tags = {"用户端-订单"}) - public R<Object> shareAllowanceMoney(@RequestParam("orderId") String orderId, @RequestParam("prizeId") String prizeId) { - Prize data = adminClient.prizeDetail(prizeId).getData(); - if (null == data) { - return R.fail(adminClient.prizeDetail(prizeId).getMsg()); - } - if(Objects.isNull(data.getPrizeType()) || data.getPrizeType() == 2){ - return R.fail("该津贴为非补贴金类型"); - } - String prizeMoney; - if (data.getPrizeType()==1) { - prizeMoney = data.getPrizeName().substring(Constants.ONE); + if (data.getPrizeType() == 1) { + // 查询服务回收补贴金 + RecoveryServe recoveryServe = recoveryServeService.getById(serveId); + prizeMoney = recoveryServe.getRecycleSubsidy().toString(); } else { prizeMoney = "0"; } -- Gitblit v1.7.1