Pu Zhibing
2024-11-06 a2710eae94f1303434adfcdc3e23c5efaba151c5
ruoyi-service/ruoyi-order/src/main/java/com/ruoyi/order/controller/TChargingOrderController.java
@@ -526,7 +526,7 @@
    @ResponseBody
    @PostMapping(value = "/securityDetection")
    public void securityDetection(@RequestBody SecurityDetectionVO securityDetection){
        log.error("-------------------安全检测数据-------------------:" + securityDetection);
        log.info("-------------------安全检测数据-------------------:" + securityDetection);
        chargingOrderService.securityDetection(securityDetection);
    }
    
@@ -537,7 +537,7 @@
    @ResponseBody
    @PostMapping(value = "/startChargeSuccessfully")
    public void startChargeSuccessfully(@RequestBody PlatformStartChargingReplyMessageVO message){
        log.error("-------------------远程启动充电请求应答-------------------:" + message);
        log.info("-------------------远程启动充电请求应答-------------------:" + message);
        chargingOrderService.startChargeSuccessfully(message);
    }
    
@@ -548,21 +548,10 @@
     */
    @ResponseBody
    @PostMapping(value = "/chargingOrderALICallback")
    public void chargingOrderALICallback(@RequestBody AliQueryOrder aliQueryOrder, HttpServletResponse response) {
        try {
            String out_trade_no = aliQueryOrder.getOutTradeNo();
            String transaction_id = aliQueryOrder.getTradeNo();
            String attach = aliQueryOrder.getPassbackParams();
            AjaxResult ajaxResult = chargingOrderService.chargingOrderCallback(2, out_trade_no, transaction_id, attach);
            if (ajaxResult.isSuccess()) {
                PrintWriter writer = response.getWriter();
                writer.println("success");
                writer.flush();
                writer.close();
            }
        } catch (Exception e) {
            e.printStackTrace();
        }
    public void chargingOrderALICallback(@RequestParam("out_trade_no") String out_trade_no,
                                         @RequestParam("transaction_id") String transaction_id,
                                         @RequestParam("attach") String attach) {
        chargingOrderService.chargingOrderCallback(2, out_trade_no, transaction_id, attach);
    }
    
    
@@ -625,7 +614,7 @@
     */
    @PostMapping("/terminateSuccessfulResponse")
    public void terminateSuccessfulResponse(@RequestBody PlatformStopChargingReplyVO platformStopChargingReply){
        log.error("-------------------远程停止充电请求应答-------------------:" + platformStopChargingReply);
        log.info("-------------------远程停止充电请求应答-------------------:" + platformStopChargingReply);
        chargingOrderService.terminateSuccessfulResponse(platformStopChargingReply);
    }
    
@@ -636,7 +625,7 @@
     */
    @PostMapping("/endChargeBillingCharge")
    public void endChargeBillingCharge(@RequestBody TransactionRecordMessageVO vo){
        log.error("-------------------停止充电返回账单后计算费用及修改业务状态-------------------:" + vo);
        log.info("-------------------停止充电返回账单后计算费用及修改业务状态-------------------:" + vo);
        chargingOrderService.endChargeBillingCharge(vo);
    }
    
@@ -1806,7 +1795,7 @@
     */
    @PostMapping("/endCharge")
    public void endCharge(@RequestParam("code") String code){
        log.error(code + ":-------------------充电桩自动结束充电-------------------");
        log.info(code + ":-------------------充电桩自动结束充电-------------------");
        chargingOrderService.endCharge(code, 2);
    }
@@ -1816,7 +1805,7 @@
     */
    @PostMapping("/excelEndCharge")
    public void excelEndCharge(@RequestParam("code") String code){
        log.error(code + ":-------------------充电异常,停止充电-------------------");
        log.info(code + ":-------------------充电异常,停止充电-------------------");
        chargingOrderService.excelEndCharge(code);
    }