luodangjia
2024-11-04 e0fc8f7e2230b51e3bbe8dea43790cf11b7170e9
ruoyi-service/ruoyi-order/src/main/java/com/ruoyi/order/controller/TChargingOrderController.java
@@ -197,6 +197,7 @@
                payOrderInfoDto.setPayTime(byId.getCreateTime());
                payOrderInfoDto.setRefundAmount(byId.getRefundAmount());
                payOrderInfoDto.setRechargeAmount(byId.getRechargeAmount());
                payOrderInfoDto.setFinalAmount(byId.getRechargeAmount().subtract(byId.getRefundAmount()));
                return R.ok(payOrderInfoDto);
            case 2:
                TShoppingOrder byId1 = shoppingOrderService.getById(orderId);
@@ -209,6 +210,7 @@
                payOrderInfoDto1.setPayTime(byId1.getCreateTime());
                payOrderInfoDto1.setRefundAmount(byId1.getRefundAmount());
                payOrderInfoDto1.setRechargeAmount(byId1.getPaymentAmount());
                payOrderInfoDto1.setFinalAmount(byId1.getPaymentAmount().subtract(byId1.getRefundAmount()));
                return R.ok(payOrderInfoDto1);
            case 3:
                TVipOrder byId2 = vipOrderService.getById(orderId);
@@ -221,6 +223,7 @@
                payOrderInfoDto2.setPayTime(byId2.getCreateTime());
                payOrderInfoDto2.setRefundAmount(byId2.getRefundAmount());
                payOrderInfoDto2.setRechargeAmount(byId2.getPaymentAmount());
                payOrderInfoDto2.setFinalAmount(byId2.getPaymentAmount().subtract(byId2.getRefundAmount()));
                return R.ok(payOrderInfoDto2);
            //todo luo 停车场订单
//                case 4:
@@ -1278,11 +1281,13 @@
            brands.add(objectMap.get("vehicle_brand").toString());
        }
        Long count = chargingOrderService.countCar(brands);
        Map<String, Object> others = new HashMap<>();
        others.put("vehicle_brand","其他");
        others.put("counts",count);
        carBrandMap.add(others);
        if (carBrandMap.size()>=5) {
            Long count = chargingOrderService.countCar(brands);
            Map<String, Object> others = new HashMap<>();
            others.put("vehicle_brand", "其他");
            others.put("counts", count);
            carBrandMap.add(others);
        }
        //本地车数量
        Map<String,Object> localCarMap = chargingOrderService.countLocalCar();