update 分页查询场站订单排行

This commit is contained in:
Lemon
2026-05-25 13:33:35 +08:00
parent ff6c95f84b
commit 9a6ec3e792
4 changed files with 54 additions and 39 deletions

View File

@@ -6,6 +6,7 @@ import com.jsowell.common.core.page.PageResponse;
import com.jsowell.common.enums.ykc.ReturnCodeEnum;
import com.jsowell.common.exception.BusinessException;
import com.jsowell.common.response.RestApiResponse;
import com.google.common.collect.ImmutableMap;
import com.jsowell.pile.dto.MerchantOrderReportDTO;
import com.jsowell.pile.dto.ParkingCouponRecordQueryDTO;
import com.jsowell.pile.dto.business.BusinessEfficiencyQueryDTO;
@@ -17,7 +18,6 @@ import com.jsowell.pile.vo.uniapp.business.BusinessEfficiencyVO;
import com.jsowell.pile.vo.uniapp.business.BusinessGunEfficiencyAnalysisVO;
import com.jsowell.pile.vo.uniapp.business.BusinessOperationAnalysisVO;
import com.jsowell.pile.vo.uniapp.business.BusinessScaleVO;
import com.jsowell.pile.vo.uniapp.business.BusinessStationRankVO;
import com.jsowell.pile.vo.web.MerchantOrderReportVO;
import org.apache.commons.lang3.StringUtils;
import org.springframework.beans.factory.annotation.Autowired;
@@ -26,8 +26,6 @@ import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import java.util.List;
/**
* 运营端财务信息相关Controller
*
@@ -212,10 +210,10 @@ public class BusinessFinancialController extends BaseController {
}
/**
* 查询场站订单排行
* 分页查询场站订单排行
*
* @param dto 查询参数
* @return 场站订单排行列表按订单数量降序)
* @param dto 查询参数含pageNum、pageSize
* @return 分页结果(场站订单排行列表按订单数量降序)
*/
@PostMapping("/stationOrderRank")
public RestApiResponse<?> getStationOrderRank(@RequestBody BusinessOperationAnalysisQueryDTO dto) {
@@ -225,10 +223,10 @@ public class BusinessFinancialController extends BaseController {
if (dto == null) {
throw new BusinessException(ReturnCodeEnum.CODE_PARAM_NOT_NULL_ERROR);
}
List<BusinessStationRankVO> result = businessFinancialService.getStationOrderRank(dto);
response = new RestApiResponse<>(result);
logger.info("查询场站订单排行成功 startTime:{}, endTime:{}, 站点数量:{}",
dto.getStartTime(), dto.getEndTime(), result.size());
PageResponse pageResponse = businessFinancialService.getStationOrderRank(dto);
response = new RestApiResponse<>(ImmutableMap.of("pageResponse", pageResponse));
logger.info("查询场站订单排行成功 startTime:{}, endTime:{}, total:{}",
dto.getStartTime(), dto.getEndTime(), pageResponse.getTotal());
} catch (BusinessException e) {
logger.warn("查询场站订单排行业务异常 code:{}, message:{}", e.getCode(), e.getMessage(), e);
response = new RestApiResponse<>(e.getCode(), e.getMessage());