44323
2024-05-17 7db1c59608f6fa48eb7c47be84d808a7ce3e1d23
ManagementIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/controller/TSubsidyController.java
@@ -358,33 +358,33 @@
            res.add(grantVO);
        }
        // 已领取司机奖励
        for (DriverActivityHistory driverActivityHistory : driverActivityHistories) {
            GrantVO grantVO = new GrantVO();
            grantVO.setInsertTime(format.format(driverActivityHistory.getInsertTime()));
            grantVO.setType("司机奖励");
            grantVO.setAmount(driverActivityHistory.getMoney().toString());
            TDriver tDriver = driverService.selectById(driverActivityHistory.getDriverId());
            if (tDriver!=null){
                grantVO.setName(tDriver.getFirstName()+tDriver.getLastName());
            }
            Integer type1 = driverActivityHistory.getType();
            switch (type1){
                case 1:
                    grantVO.setRemark("邀请司机注册");
                    break;
                case 2:
                    grantVO.setRemark("邀请用户注册");
                    break;
                case 3:
                    grantVO.setRemark("累计在线");
                    break;
                case 4:
                    grantVO.setRemark("订单量");
                    break;
            }
            driver = driver.add(new BigDecimal(driverActivityHistory.getMoney().toString()));
            res.add(grantVO);
        }
//        for (DriverActivityHistory driverActivityHistory : driverActivityHistories) {
//            GrantVO grantVO = new GrantVO();
//            grantVO.setInsertTime(format.format(driverActivityHistory.getInsertTime()));
//            grantVO.setType("司机奖励");
//            grantVO.setAmount(driverActivityHistory.getMoney().toString());
//            TDriver tDriver = driverService.selectById(driverActivityHistory.getDriverId());
//            if (tDriver!=null){
//                grantVO.setName(tDriver.getFirstName()+tDriver.getLastName());
//            }
//            Integer type1 = driverActivityHistory.getType();
//            switch (type1){
//                case 1:
//                    grantVO.setRemark("邀请司机注册");
//                    break;
//                case 2:
//                    grantVO.setRemark("邀请用户注册");
//                    break;
//                case 3:
//                    grantVO.setRemark("累计在线");
//                    break;
//                case 4:
//                    grantVO.setRemark("订单量");
//                    break;
//            }
//            driver = driver.add(new BigDecimal(driverActivityHistory.getMoney().toString()));
//            res.add(grantVO);
//        }
        total = total.add(redPackage).add(coupon).add(discount).add(driver);
        return res;
    }