jiaosong
2023-10-23 3b48dbfe08bf2bcaeba2f8f9ff63f1599407fcdd
server/services/src/main/java/com/doumee/service/business/impl/PricingDetailServiceImpl.java
@@ -90,12 +90,12 @@
        return pricingDetail.getId();
    }
    private  String getRoleNameByParam(BigDecimal basePrice, Integer baseTime, BigDecimal unitPrice, Integer unitTime) {
        String title = "";
    public static  String getRoleNameByParam(BigDecimal basePrice, Integer baseTime, BigDecimal unitPrice, Integer unitTime) {
        String title = "计费规则:";
        if(baseTime < 0){
            title = "规则:"+Constants.translateMoney(basePrice).doubleValue()+"元畅骑一整天";
            title = basePrice.doubleValue()+"元畅骑一整天";
        }else {
            title = "规则:起步";
            title = "起步";
            int time = baseTime / 60;
            int min = baseTime % 60;
            if(time > 0){
@@ -104,8 +104,8 @@
            if(min >0){
                title += min+"分钟";
            }
            title = Constants.translateMoney(unitPrice).doubleValue()
                    +"元,超过后"+Constants.translateMoney(basePrice).doubleValue()+"元/"
            title += Constants.translateMoney(unitPrice).doubleValue()
                    +"元,超过后"+basePrice.doubleValue()+"元/"
                    +unitTime+"分钟";
        }
        return  title;
@@ -230,6 +230,7 @@
            put.setBikeTypeId(s.getId());
            put.setPricePramId(pricingDetail.getPricePramId());
            put.setBikeTypeName(s.getName());
            put.setSortnum(s.getSortnum());
            put.setBasePrice(Objects.nonNull(put.getBasePrice()) ? Constants.translateMoney(put.getBasePrice()) : null);
            put.setHolidayBasePrice(Objects.nonNull(put.getHolidayBasePrice()) ? Constants.translateMoney(put.getHolidayBasePrice()):null);
            put.setUnitPrice(Objects.nonNull(put.getUnitPrice()) ? Constants.translateMoney(put.getUnitPrice()):null);