puzhibing
2026-03-27 0c7773cf3833b529a9bcb16480161ad719dbe596
xp-robotaxi-operation-boot/src/main/java/com/xiaopeng/operation/controller/XpPricingController.java
@@ -17,6 +17,7 @@
import com.xiaopeng.operation.dto.*;
import com.xiaopeng.operation.query.PricingPageListQuery;
import com.xiaopeng.operation.service.*;
import com.xiaopeng.operation.utils.ImageTagProcessor;
import com.xiaopeng.operation.vo.PricingPageListVO;
import com.xiaopeng.operation.vo.SaveOrderVo;
import com.xiaopeng.unifiedverification.interceptor.XpClientCheck;
@@ -49,13 +50,15 @@
    private final UserResourcesClient userResourcesClient;
    private final IXpWhitelistService xpWhitelistService;
    private final XpOpenCityService xpOpenCityService;
    private final ImageTagProcessor imageTagProcessor;
    public XpPricingController(XpPricingService xpPricingService, IXpGeoQueryEntityService xpGeoQueryEntityService, UserResourcesClient userResourcesClient, IXpWhitelistService xpWhitelistService, XpRegionService xpRegionService, XpOpenCityService xpOpenCityService) {
    public XpPricingController(XpPricingService xpPricingService, IXpGeoQueryEntityService xpGeoQueryEntityService, UserResourcesClient userResourcesClient, IXpWhitelistService xpWhitelistService, XpRegionService xpRegionService, XpOpenCityService xpOpenCityService, ImageTagProcessor imageTagProcessor) {
        this.xpPricingService = xpPricingService;
        this.xpGeoQueryEntityService = xpGeoQueryEntityService;
        this.userResourcesClient = userResourcesClient;
        this.xpWhitelistService = xpWhitelistService;
        this.xpOpenCityService = xpOpenCityService;
        this.imageTagProcessor = imageTagProcessor;
    }
@@ -177,6 +180,13 @@
        //获取城市信息
        String cityName = xpOpenCityService.getNameWithCityName(pricing.getCityId());
        pricing.setCityName(cityName);
        String priceRule = pricing.getPriceRule();
        if (priceRule != null && priceRule.contains("<img")) {
            priceRule = imageTagProcessor.replaceImgSrcWithDownloadUrl(priceRule);
            pricing.setPriceRule(priceRule);
        }
        return R.ok(pricing);
    }