mirror of
https://codeup.aliyun.com/67c68d4e484ca2f0a13ac3c1/ydc/jsowell-charger-web.git
synced 2026-04-20 11:05:18 +08:00
update 统计订单数据
This commit is contained in:
@@ -371,11 +371,25 @@ public class OrderBasicInfoServiceImpl implements IOrderBasicInfoService {
|
||||
*/
|
||||
@Override
|
||||
public OrderTotalDataVO getOrderTotalDataV2(QueryOrderDTO dto) {
|
||||
// 确定查询的站点
|
||||
List<String> stationIdList = Lists.newArrayList();
|
||||
if (StringUtils.isNotBlank(dto.getStationId())) {
|
||||
stationIdList.add(dto.getStationId());
|
||||
}
|
||||
if (StringUtils.isNotBlank(dto.getMerchantId())) {
|
||||
List<PileStationInfo> pileStationInfos = pileStationInfoService.selectStationListByMerchantId(Long.parseLong(dto.getMerchantId()));
|
||||
if (CollectionUtils.isNotEmpty(pileStationInfos)) {
|
||||
List<String> collect = pileStationInfos.stream()
|
||||
.map(x -> String.valueOf(x.getId()))
|
||||
.collect(Collectors.toList());
|
||||
stationIdList.addAll(collect);
|
||||
}
|
||||
}
|
||||
|
||||
OrderTotalDataVO vo = new OrderTotalDataVO();
|
||||
String startTime = dto.getStartTime();
|
||||
String endTime = dto.getEndTime();
|
||||
vo.setDateDescription(startTime + " - " + endTime);
|
||||
List<String> stationIdList = Lists.newArrayList(dto.getStationId());
|
||||
List<SettleOrderReport> settleOrderReports = settleOrderReportService.queryOrderReport(stationIdList, startTime, endTime);
|
||||
// 总消费金额
|
||||
BigDecimal sumOrderAmount = BigDecimal.ZERO;
|
||||
|
||||
Reference in New Issue
Block a user