Commit f02a9ced authored by 周健威's avatar 周健威

修改订单明细bug

parent 44747221
......@@ -113,8 +113,11 @@ public class VehicleItemDTO extends OrderItem {
}
BigDecimal usedAmount = BigDecimal.ZERO;
for(VMCalendarPriceCostDTO vmcpcd : vmcpds) {
usedAmount.add(vmcpcd.getPrice());
// for(VMCalendarPriceCostDTO vmcpcd : vmcpds) {
// usedAmount.add(vmcpcd.getPrice());
// }
for(int i = 0; i < useDays; i++) {
usedAmount = usedAmount.add(vmcpds.get(i).getPrice());
}
return usedAmount;
}
......@@ -133,11 +136,11 @@ public class VehicleItemDTO extends OrderItem {
BigDecimal freeAmount = BigDecimal.ZERO;
if(null != offsetDay) {
for(int i = 0; i < offsetDay; i++) {
freeAmount.add(vmcpds.get(i).getFreeAmount());
freeAmount = freeAmount.add(vmcpds.get(i).getFreeAmount());
}
}else {
for(VMCalendarPriceCostDTO vmcpcd : vmcpds) {
freeAmount.add(vmcpcd.getFreeAmount());
freeAmount = freeAmount.add(vmcpcd.getFreeAmount());
}
}
return freeAmount;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment