mirror of
https://codeup.aliyun.com/67c68d4e484ca2f0a13ac3c1/ydc/jsowell-charger-web.git
synced 2026-04-20 02:55:04 +08:00
bugfix 修复运营端小程序首页查询数据sql报错
This commit is contained in:
@@ -12,9 +12,12 @@ import com.jsowell.pile.dto.business.StationBusinessAnalyzeInfoDTO;
|
||||
import com.jsowell.pile.dto.business.StationStatisticsInfoDTO;
|
||||
import com.jsowell.pile.service.OrderBasicInfoService;
|
||||
import com.jsowell.pile.service.PileStationInfoService;
|
||||
import com.jsowell.pile.util.UserUtils;
|
||||
import com.jsowell.pile.vo.base.LoginUserDetailVO;
|
||||
import com.jsowell.pile.vo.uniapp.business.StationBusinessAnalyzeInfoVO;
|
||||
import com.jsowell.pile.vo.uniapp.business.StationStatisticsInfosVO;
|
||||
import com.jsowell.pile.vo.web.StationSelectVO;
|
||||
import org.apache.commons.collections4.CollectionUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
@@ -83,6 +86,12 @@ public class BusinessStationInfoController extends BaseController {
|
||||
public RestApiResponse<?> getStationBusinessAnalyzeInfo(@RequestBody StationBusinessAnalyzeInfoDTO dto){
|
||||
RestApiResponse<?> response = null;
|
||||
try {
|
||||
// 获取登录账号信息
|
||||
LoginUserDetailVO loginUserDetail = UserUtils.getLoginUserDetail();
|
||||
List<String> merchantIdList = loginUserDetail.getFirstMerchantIdList();
|
||||
if (CollectionUtils.isEmpty(dto.getStationIds())) {
|
||||
dto.setStationIds(pileStationInfoService.getStationIdsByMerchantIds(merchantIdList));
|
||||
}
|
||||
StationBusinessAnalyzeInfoVO vo = pileStationInfoService.getStationBusinessAnalyzeInfo(dto);
|
||||
response = new RestApiResponse<>(ImmutableMap.of("stationBusinessAnalyzeInfoVO", vo));
|
||||
} catch (Exception e) {
|
||||
@@ -145,6 +154,12 @@ public class BusinessStationInfoController extends BaseController {
|
||||
public RestApiResponse<?> getStationOrderQuantityInfo(@RequestBody StationBusinessAnalyzeInfoDTO dto) {
|
||||
RestApiResponse<?> response = null;
|
||||
try {
|
||||
// 获取登录账号信息
|
||||
LoginUserDetailVO loginUserDetail = UserUtils.getLoginUserDetail();
|
||||
List<String> merchantIdList = loginUserDetail.getFirstMerchantIdList();
|
||||
if (CollectionUtils.isEmpty(dto.getStationIds())) {
|
||||
dto.setStationIds(pileStationInfoService.getStationIdsByMerchantIds(merchantIdList));
|
||||
}
|
||||
StationBusinessAnalyzeInfoVO vo = pileStationInfoService.getStationOrderQuantityInfo(dto);
|
||||
response = new RestApiResponse<>(ImmutableMap.of("stationBusinessAnalyzeInfoVO", vo));
|
||||
} catch (Exception e) {
|
||||
@@ -163,6 +178,12 @@ public class BusinessStationInfoController extends BaseController {
|
||||
public RestApiResponse<?> getStationConnectorUsedInfo(@RequestBody StationBusinessAnalyzeInfoDTO dto) {
|
||||
RestApiResponse<?> response = null;
|
||||
try {
|
||||
// 获取登录账号信息
|
||||
LoginUserDetailVO loginUserDetail = UserUtils.getLoginUserDetail();
|
||||
List<String> merchantIdList = loginUserDetail.getFirstMerchantIdList();
|
||||
if (CollectionUtils.isEmpty(dto.getStationIds())) {
|
||||
dto.setStationIds(pileStationInfoService.getStationIdsByMerchantIds(merchantIdList));
|
||||
}
|
||||
StationBusinessAnalyzeInfoVO vo = pileStationInfoService.getStationConnectorUsedInfo(dto);
|
||||
response = new RestApiResponse<>(ImmutableMap.of("stationBusinessAnalyzeInfoVO", vo));
|
||||
} catch (Exception e) {
|
||||
|
||||
Reference in New Issue
Block a user