Commit 2734290c authored by huangcb's avatar huangcb

word转pdf异步模式bug对应、linux中文乱码问题对应

parent 424a169e
...@@ -56,7 +56,7 @@ public class BaseDataComponent { ...@@ -56,7 +56,7 @@ public class BaseDataComponent {
redisComponent.set(this.getAllRegionMapCacheKey(), allRegionMap.toJSONString(), ALL_REGION_MAP_CACHE_TIME); redisComponent.set(this.getAllRegionMapCacheKey(), allRegionMap.toJSONString(), ALL_REGION_MAP_CACHE_TIME);
} }
} catch (Exception e) { } catch (Exception e) {
log.error("调用[基础服务]获取全国省市行政区划(键值对)失败:" + e.getMessage()); log.error("调用[基础服务]获取全国省市行政区划(键值对)失败:{}", e.getMessage(), e);
} }
} }
......
...@@ -84,20 +84,20 @@ public class RestLogFilter implements Filter { ...@@ -84,20 +84,20 @@ public class RestLogFilter implements Filter {
bodyStr = sb.toString(); bodyStr = sb.toString();
} }
} catch (IOException e) { } catch (IOException e) {
log.error("解析post参数时发生错误:{}", e.getMessage()); log.error("解析post参数时发生错误:{}", e.getMessage(), e);
} finally { } finally {
if (inputStream != null) { if (inputStream != null) {
try { try {
inputStream.close(); inputStream.close();
} catch (IOException e) { } catch (IOException e) {
e.printStackTrace(); log.error(e.getMessage(), e);
} }
} }
if (reader != null) { if (reader != null) {
try { try {
reader.close(); reader.close();
} catch (IOException e) { } catch (IOException e) {
e.printStackTrace(); log.error(e.getMessage(), e);
} }
} }
} }
......
...@@ -22,6 +22,9 @@ public class ReqUtils { ...@@ -22,6 +22,9 @@ public class ReqUtils {
public static String getRequestHeader(String headerKey) { public static String getRequestHeader(String headerKey) {
ServletRequestAttributes servletRequestAttributes = (ServletRequestAttributes) RequestContextHolder.getRequestAttributes(); ServletRequestAttributes servletRequestAttributes = (ServletRequestAttributes) RequestContextHolder.getRequestAttributes();
if (null == servletRequestAttributes) {
return null;
}
HttpServletRequest request = servletRequestAttributes.getRequest(); HttpServletRequest request = servletRequestAttributes.getRequest();
return request.getHeader(headerKey); return request.getHeader(headerKey);
} }
......
...@@ -21,6 +21,7 @@ import com.esv.freight.customer.module.carrier.form.CarrierQueryForm; ...@@ -21,6 +21,7 @@ import com.esv.freight.customer.module.carrier.form.CarrierQueryForm;
import com.esv.freight.customer.module.carrier.service.CarrierAccountService; import com.esv.freight.customer.module.carrier.service.CarrierAccountService;
import com.esv.freight.customer.module.carrier.service.CarrierInfoService; import com.esv.freight.customer.module.carrier.service.CarrierInfoService;
import com.esv.freight.customer.module.carrier.vo.CarrierInfoListVO; import com.esv.freight.customer.module.carrier.vo.CarrierInfoListVO;
import lombok.extern.slf4j.Slf4j;
import org.apache.commons.lang3.StringUtils; import org.apache.commons.lang3.StringUtils;
import org.springframework.beans.BeanUtils; import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
...@@ -29,7 +30,7 @@ import org.springframework.stereotype.Service; ...@@ -29,7 +30,7 @@ import org.springframework.stereotype.Service;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.List; import java.util.List;
@Slf4j
@Service("carrierAccountService") @Service("carrierAccountService")
public class CarrierAccountServiceImpl extends ServiceImpl<CarrierAccountDao, CarrierAccountEntity> implements CarrierAccountService { public class CarrierAccountServiceImpl extends ServiceImpl<CarrierAccountDao, CarrierAccountEntity> implements CarrierAccountService {
...@@ -103,7 +104,7 @@ public class CarrierAccountServiceImpl extends ServiceImpl<CarrierAccountDao, Ca ...@@ -103,7 +104,7 @@ public class CarrierAccountServiceImpl extends ServiceImpl<CarrierAccountDao, Ca
try { try {
batchIdResJson = FeignUtils.getFeignResultData(feignBaseService.getBatchId(batchIdReqJson)); batchIdResJson = FeignUtils.getFeignResultData(feignBaseService.getBatchId(batchIdReqJson));
} catch (Exception e) { } catch (Exception e) {
log.error("调用[基础服务]生成承运商编号失败:" + e.getMessage()); log.error("调用[基础服务]生成承运商编号失败:{}", e.getMessage(), e);
throw new EException("生成承运商编号时发生错误"); throw new EException("生成承运商编号时发生错误");
} }
String carrierNumber = batchIdResJson.getString("batchId"); String carrierNumber = batchIdResJson.getString("batchId");
......
package com.esv.freight.customer.module.contract.service;
import com.esv.freight.customer.module.contract.entity.ContractOnlineRecordEntity;
/**
* @description:
* @project: freight-customer-service
* @name: com.esv.freight.customer.module.contract.service.PdfService
* @author: 黄朝斌
* @email: huangchaobin@esvtek.com
* @createTime: 2020/05/28 20:16
* @version:1.0
*/
public interface PdfService {
/**
* description 异步保存线上合同目标文件(PDF)及信息
* param [traceId, entity, fileBytes]
* return void
* author HuangChaobin
* createTime 2020/05/28 20:17
**/
public void asyncSaveTargetFileInfo(String traceId, ContractOnlineRecordEntity entity, byte[] fileBytes);
}
package com.esv.freight.customer.module.contract.service.impl;
import com.alibaba.fastjson.JSONObject;
import com.aspose.words.Document;
import com.aspose.words.FontSettings;
import com.aspose.words.SaveFormat;
import com.esv.freight.customer.common.constants.CommonConstants;
import com.esv.freight.customer.common.util.FeignUtils;
import com.esv.freight.customer.common.util.InputStreamUtils;
import com.esv.freight.customer.feign.FeignFileService;
import com.esv.freight.customer.module.contract.entity.ContractOnlineRecordEntity;
import com.esv.freight.customer.module.contract.service.ContractOnlineRecordService;
import com.esv.freight.customer.module.contract.service.PdfService;
import lombok.extern.slf4j.Slf4j;
import org.apache.commons.io.IOUtils;
import org.apache.commons.lang3.StringUtils;
import org.slf4j.MDC;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.scheduling.annotation.Async;
import org.springframework.stereotype.Service;
import java.io.ByteArrayOutputStream;
import java.io.InputStream;
import java.util.Base64;
import java.util.UUID;
/**
* @description:
* @project: freight-customer-service
* @name: com.esv.freight.customer.module.contract.service.impl.PdfServiceImpl
* @author: 黄朝斌
* @email: huangchaobin@esvtek.com
* @createTime: 2020/05/28 20:17
* @version:1.0
*/
@Service("pdfService")
@Slf4j
public class PdfServiceImpl implements PdfService {
@Autowired
private FeignFileService feignFileService;
@Autowired
private ContractOnlineRecordService contractOnlineRecordService;
@Value("${font.windows.dir}")
private String fontWindowsDir;
@Override
@Async
public void asyncSaveTargetFileInfo(String traceId, ContractOnlineRecordEntity entity, byte[] fileBytes) {
String contractNumber = entity.getContractNumber();
if (StringUtils.isEmpty(traceId) || CommonConstants.NULL_STRING.equalsIgnoreCase(traceId)) {
traceId = UUID.randomUUID().toString().replace("-", "");
}
MDC.put("traceId", traceId);
log.info("------异步保存合同[{}]目标文件及信息开始------", contractNumber);
// 转换源文件为PDF
ByteArrayOutputStream outputStream = new ByteArrayOutputStream();
InputStream inputStream = InputStreamUtils.byte2InputStream(fileBytes);
byte[] targetFileBytes;
try {
String os = System.getProperty("os.name").toLowerCase();
if (!os.contains("windows")) {
FontSettings fontSettings = new FontSettings();
fontSettings.setFontsFolder(fontWindowsDir, false);
}
Document document = new Document(inputStream);
document.save(outputStream, SaveFormat.PDF);
targetFileBytes = outputStream.toByteArray();
} catch (Exception e) {
log.error("合同[{}]转换为PDF时失败:{}", contractNumber, e.getMessage());
log.info("------异步保存合同[{}]目标文件及信息结束------", contractNumber);
return;
} finally {
IOUtils.closeQuietly(inputStream);
IOUtils.closeQuietly(outputStream);
}
// 保存PDF文件
JSONObject feignReqJson = new JSONObject();
feignReqJson.put("fileType", "pdf");
feignReqJson.put("fileName", "电子合同-" + contractNumber + ".pdf");
feignReqJson.put("fileData", Base64.getEncoder().encodeToString(targetFileBytes));
JSONObject feignResJson;
try {
feignResJson = FeignUtils.getFeignResultData(feignFileService.uploadSingleFile(feignReqJson));
} catch (Exception e) {
log.error("调用[文件服务]上传目标合同[{}]文件数据失败:{}", contractNumber, e.getMessage(), e);
log.info("------异步保存合同[{}]目标文件及信息结束------", contractNumber);
return;
}
// 更新合同记录信息
ContractOnlineRecordEntity onlineRecordEntity = new ContractOnlineRecordEntity();
onlineRecordEntity.setId(entity.getId());
onlineRecordEntity.setTargetFileId(feignResJson.getString("id"));
onlineRecordEntity.setTargetFileUrl(feignResJson.getString("url"));
contractOnlineRecordService.getBaseMapper().updateById(onlineRecordEntity);
log.info("------异步保存合同[{}]目标文件及信息结束------", contractNumber);
}
}
...@@ -248,7 +248,7 @@ public class DriverAccountServiceImpl extends ServiceImpl<DriverAccountDao, Driv ...@@ -248,7 +248,7 @@ public class DriverAccountServiceImpl extends ServiceImpl<DriverAccountDao, Driv
JSONObject resultJson = feignAppService.blockDriverAccount(bodyJson); JSONObject resultJson = feignAppService.blockDriverAccount(bodyJson);
log.info("停用帐号Feign通知APP后台响应结果:{}", resultJson.toJSONString()); log.info("停用帐号Feign通知APP后台响应结果:{}", resultJson.toJSONString());
} catch (Exception e) { } catch (Exception e) {
log.error("停用帐号Feign通知APP后台发生错误:" + e.getMessage(), e); log.error("停用帐号Feign通知APP后台发生错误:{}", e.getMessage(), e);
} }
return flag; return flag;
......
...@@ -26,6 +26,7 @@ import com.esv.freight.customer.module.vehicle.entity.VehicleEntity; ...@@ -26,6 +26,7 @@ import com.esv.freight.customer.module.vehicle.entity.VehicleEntity;
import com.esv.freight.customer.module.vehicle.service.VehicleDriverService; import com.esv.freight.customer.module.vehicle.service.VehicleDriverService;
import com.esv.freight.customer.module.vehicle.service.VehicleService; import com.esv.freight.customer.module.vehicle.service.VehicleService;
import com.esv.freight.customer.module.vehicle.vo.VehicleDetailVO; import com.esv.freight.customer.module.vehicle.vo.VehicleDetailVO;
import lombok.extern.slf4j.Slf4j;
import org.apache.commons.lang3.StringUtils; import org.apache.commons.lang3.StringUtils;
import org.springframework.beans.BeanUtils; import org.springframework.beans.BeanUtils;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
...@@ -45,6 +46,7 @@ import java.util.Map; ...@@ -45,6 +46,7 @@ import java.util.Map;
* @version:1.0 * @version:1.0
*/ */
@Service("driverVehicleService") @Service("driverVehicleService")
@Slf4j
public class DriverVehicleServiceImpl implements DriverVehicleService { public class DriverVehicleServiceImpl implements DriverVehicleService {
private ErrorMessageComponent errorMessageComponent; private ErrorMessageComponent errorMessageComponent;
......
...@@ -17,6 +17,7 @@ import com.esv.freight.customer.module.goodsowner.vo.account4address.AccountAndA ...@@ -17,6 +17,7 @@ import com.esv.freight.customer.module.goodsowner.vo.account4address.AccountAndA
import com.esv.freight.customer.module.goodsowner.vo.account4address.AccountVO; import com.esv.freight.customer.module.goodsowner.vo.account4address.AccountVO;
import com.esv.freight.customer.module.goodsowner.vo.account4address.DeliveryAddressVO; import com.esv.freight.customer.module.goodsowner.vo.account4address.DeliveryAddressVO;
import com.esv.freight.customer.module.goodsowner.vo.account4address.ReceiveAddressVO; import com.esv.freight.customer.module.goodsowner.vo.account4address.ReceiveAddressVO;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.BeanUtils; import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
...@@ -31,6 +32,7 @@ import org.springframework.stereotype.Service; ...@@ -31,6 +32,7 @@ import org.springframework.stereotype.Service;
* @version:1.0 * @version:1.0
*/ */
@Service("accountAndAddressService") @Service("accountAndAddressService")
@Slf4j
public class AccountAndAddressServiceIpml implements AccountAndAddressService { public class AccountAndAddressServiceIpml implements AccountAndAddressService {
private ErrorMessageComponent errorMessageComponent; private ErrorMessageComponent errorMessageComponent;
......
...@@ -21,6 +21,7 @@ import com.esv.freight.customer.module.goodsowner.service.DeliveryAddressService ...@@ -21,6 +21,7 @@ import com.esv.freight.customer.module.goodsowner.service.DeliveryAddressService
import com.esv.freight.customer.module.goodsowner.vo.AddressBriefVO; import com.esv.freight.customer.module.goodsowner.vo.AddressBriefVO;
import com.esv.freight.customer.module.goodsowner.vo.DeliveryAddressListVO; import com.esv.freight.customer.module.goodsowner.vo.DeliveryAddressListVO;
import com.esv.freight.customer.module.goodsowner.vo.DeliveryAddressVO; import com.esv.freight.customer.module.goodsowner.vo.DeliveryAddressVO;
import lombok.extern.slf4j.Slf4j;
import org.apache.commons.lang3.StringUtils; import org.apache.commons.lang3.StringUtils;
import org.springframework.beans.BeanUtils; import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
...@@ -31,6 +32,7 @@ import java.util.*; ...@@ -31,6 +32,7 @@ import java.util.*;
@Service("deliveryAddressService") @Service("deliveryAddressService")
@Slf4j
public class DeliveryAddressServiceImpl extends ServiceImpl<DeliveryAddressDao, DeliveryAddressEntity> implements DeliveryAddressService { public class DeliveryAddressServiceImpl extends ServiceImpl<DeliveryAddressDao, DeliveryAddressEntity> implements DeliveryAddressService {
private FeignBaseService feignBaseService; private FeignBaseService feignBaseService;
...@@ -64,7 +66,7 @@ public class DeliveryAddressServiceImpl extends ServiceImpl<DeliveryAddressDao, ...@@ -64,7 +66,7 @@ public class DeliveryAddressServiceImpl extends ServiceImpl<DeliveryAddressDao,
try { try {
batchIdResJson = FeignUtils.getFeignResultData(feignBaseService.getBatchId(batchIdReqJson)); batchIdResJson = FeignUtils.getFeignResultData(feignBaseService.getBatchId(batchIdReqJson));
} catch (Exception e) { } catch (Exception e) {
log.error("调用[基础服务]生成发货地址编号失败:" + e.getMessage()); log.error("调用[基础服务]生成发货地址编号失败:{}", e.getMessage(), e);
throw new EException("生成发货地址编号时发生错误"); throw new EException("生成发货地址编号时发生错误");
} }
String addressNumber = batchIdResJson.getString("batchId"); String addressNumber = batchIdResJson.getString("batchId");
......
...@@ -29,6 +29,7 @@ import com.esv.freight.customer.module.goodsowner.service.InfoService; ...@@ -29,6 +29,7 @@ import com.esv.freight.customer.module.goodsowner.service.InfoService;
import com.esv.freight.customer.module.goodsowner.vo.AccountAvailableVO; import com.esv.freight.customer.module.goodsowner.vo.AccountAvailableVO;
import com.esv.freight.customer.module.goodsowner.vo.AccountListVO; import com.esv.freight.customer.module.goodsowner.vo.AccountListVO;
import com.esv.gateway.common.GatewayHeaders; import com.esv.gateway.common.GatewayHeaders;
import lombok.extern.slf4j.Slf4j;
import org.apache.commons.codec.digest.DigestUtils; import org.apache.commons.codec.digest.DigestUtils;
import org.apache.commons.lang3.StringUtils; import org.apache.commons.lang3.StringUtils;
import org.springframework.beans.BeanUtils; import org.springframework.beans.BeanUtils;
...@@ -41,6 +42,7 @@ import java.util.List; ...@@ -41,6 +42,7 @@ import java.util.List;
@Service("goodsOwnerAccountService") @Service("goodsOwnerAccountService")
@Slf4j
public class GoodsOwnerAccountServiceImpl extends ServiceImpl<AccountDao, GoodsOwnerAccountEntity> implements GoodsOwnerAccountService { public class GoodsOwnerAccountServiceImpl extends ServiceImpl<AccountDao, GoodsOwnerAccountEntity> implements GoodsOwnerAccountService {
private FeignBaseService feignBaseService; private FeignBaseService feignBaseService;
...@@ -99,7 +101,7 @@ public class GoodsOwnerAccountServiceImpl extends ServiceImpl<AccountDao, GoodsO ...@@ -99,7 +101,7 @@ public class GoodsOwnerAccountServiceImpl extends ServiceImpl<AccountDao, GoodsO
try { try {
batchIdResJson = FeignUtils.getFeignResultData(feignBaseService.getBatchId(batchIdReqJson)); batchIdResJson = FeignUtils.getFeignResultData(feignBaseService.getBatchId(batchIdReqJson));
} catch (Exception e) { } catch (Exception e) {
log.error("调用[基础服务]生成客户编号失败:" + e.getMessage()); log.error("调用[基础服务]生成客户编号失败:{}", e.getMessage(), e);
throw new EException("生成客户编号时发生错误"); throw new EException("生成客户编号时发生错误");
} }
String ownerNumber = batchIdResJson.getString("batchId"); String ownerNumber = batchIdResJson.getString("batchId");
...@@ -300,7 +302,7 @@ public class GoodsOwnerAccountServiceImpl extends ServiceImpl<AccountDao, GoodsO ...@@ -300,7 +302,7 @@ public class GoodsOwnerAccountServiceImpl extends ServiceImpl<AccountDao, GoodsO
try { try {
batchIdResJson = FeignUtils.getFeignResultData(feignBaseService.getBatchId(batchIdReqJson)); batchIdResJson = FeignUtils.getFeignResultData(feignBaseService.getBatchId(batchIdReqJson));
} catch (Exception e) { } catch (Exception e) {
log.error("调用[基础服务]生成客户编号失败:" + e.getMessage()); log.error("调用[基础服务]生成客户编号失败:{}", e.getMessage(), e);
throw new EException("生成客户编号时发生错误"); throw new EException("生成客户编号时发生错误");
} }
String ownerNumber = batchIdResJson.getString("batchId"); String ownerNumber = batchIdResJson.getString("batchId");
......
...@@ -21,6 +21,7 @@ import com.esv.freight.customer.module.goodsowner.service.ReceiveAddressService; ...@@ -21,6 +21,7 @@ import com.esv.freight.customer.module.goodsowner.service.ReceiveAddressService;
import com.esv.freight.customer.module.goodsowner.vo.AddressBriefVO; import com.esv.freight.customer.module.goodsowner.vo.AddressBriefVO;
import com.esv.freight.customer.module.goodsowner.vo.ReceiveAddressListVO; import com.esv.freight.customer.module.goodsowner.vo.ReceiveAddressListVO;
import com.esv.freight.customer.module.goodsowner.vo.ReceiveAddressVO; import com.esv.freight.customer.module.goodsowner.vo.ReceiveAddressVO;
import lombok.extern.slf4j.Slf4j;
import org.apache.commons.lang3.StringUtils; import org.apache.commons.lang3.StringUtils;
import org.springframework.beans.BeanUtils; import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
...@@ -31,6 +32,7 @@ import java.util.*; ...@@ -31,6 +32,7 @@ import java.util.*;
@Service("receiveAddressService") @Service("receiveAddressService")
@Slf4j
public class ReceiveAddressServiceImpl extends ServiceImpl<ReceiveAddressDao, ReceiveAddressEntity> implements ReceiveAddressService { public class ReceiveAddressServiceImpl extends ServiceImpl<ReceiveAddressDao, ReceiveAddressEntity> implements ReceiveAddressService {
private FeignBaseService feignBaseService; private FeignBaseService feignBaseService;
...@@ -64,7 +66,7 @@ public class ReceiveAddressServiceImpl extends ServiceImpl<ReceiveAddressDao, Re ...@@ -64,7 +66,7 @@ public class ReceiveAddressServiceImpl extends ServiceImpl<ReceiveAddressDao, Re
try { try {
batchIdResJson = FeignUtils.getFeignResultData(feignBaseService.getBatchId(batchIdReqJson)); batchIdResJson = FeignUtils.getFeignResultData(feignBaseService.getBatchId(batchIdReqJson));
} catch (Exception e) { } catch (Exception e) {
log.error("调用[基础服务]生成收货地址编号失败:" + e.getMessage()); log.error("调用[基础服务]生成收货地址编号失败:{}", e.getMessage(), e);
throw new EException("生成收货地址编号时发生错误"); throw new EException("生成收货地址编号时发生错误");
} }
String addressNumber = batchIdResJson.getString("batchId"); String addressNumber = batchIdResJson.getString("batchId");
......
...@@ -27,6 +27,7 @@ import com.esv.freight.customer.module.goodsowner.service.RegularlyRouteService; ...@@ -27,6 +27,7 @@ import com.esv.freight.customer.module.goodsowner.service.RegularlyRouteService;
import com.esv.freight.customer.module.goodsowner.vo.RouteDetailVO; import com.esv.freight.customer.module.goodsowner.vo.RouteDetailVO;
import com.esv.freight.customer.module.goodsowner.vo.RouteListVO; import com.esv.freight.customer.module.goodsowner.vo.RouteListVO;
import com.esv.freight.customer.module.goodsowner.vo.RouteOwnerVO; import com.esv.freight.customer.module.goodsowner.vo.RouteOwnerVO;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.BeanUtils; import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
...@@ -37,6 +38,7 @@ import java.util.List; ...@@ -37,6 +38,7 @@ import java.util.List;
@Service("regularlyRouteService") @Service("regularlyRouteService")
@Slf4j
public class RegularlyRouteServiceImpl extends ServiceImpl<RegularlyRouteDao, RegularlyRouteEntity> implements RegularlyRouteService { public class RegularlyRouteServiceImpl extends ServiceImpl<RegularlyRouteDao, RegularlyRouteEntity> implements RegularlyRouteService {
private ErrorMessageComponent errorMessageComponent; private ErrorMessageComponent errorMessageComponent;
...@@ -94,7 +96,7 @@ public class RegularlyRouteServiceImpl extends ServiceImpl<RegularlyRouteDao, Re ...@@ -94,7 +96,7 @@ public class RegularlyRouteServiceImpl extends ServiceImpl<RegularlyRouteDao, Re
try { try {
batchIdResJson = FeignUtils.getFeignResultData(feignBaseService.getBatchId(batchIdReqJson)); batchIdResJson = FeignUtils.getFeignResultData(feignBaseService.getBatchId(batchIdReqJson));
} catch (Exception e) { } catch (Exception e) {
log.error("调用[基础服务]生成路线编号失败"); log.error("调用[基础服务]生成路线编号失败:{}", e.getMessage(), e);
throw new EException("生成路线编号时发生错误"); throw new EException("生成路线编号时发生错误");
} }
String routeNumber = batchIdResJson.getString("batchId"); String routeNumber = batchIdResJson.getString("batchId");
......
...@@ -31,6 +31,7 @@ import com.esv.freight.customer.module.vehicle.service.VehicleService; ...@@ -31,6 +31,7 @@ import com.esv.freight.customer.module.vehicle.service.VehicleService;
import com.esv.freight.customer.module.vehicle.vo.VehicleAllVO; import com.esv.freight.customer.module.vehicle.vo.VehicleAllVO;
import com.esv.freight.customer.module.vehicle.vo.VehicleListVO; import com.esv.freight.customer.module.vehicle.vo.VehicleListVO;
import com.esv.gateway.common.GatewayHeaders; import com.esv.gateway.common.GatewayHeaders;
import lombok.extern.slf4j.Slf4j;
import org.apache.commons.lang3.StringUtils; import org.apache.commons.lang3.StringUtils;
import org.springframework.beans.BeanUtils; import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
...@@ -43,6 +44,7 @@ import java.util.List; ...@@ -43,6 +44,7 @@ import java.util.List;
@Service("vehicleService") @Service("vehicleService")
@Slf4j
public class VehicleServiceImpl extends ServiceImpl<VehicleDao, VehicleEntity> implements VehicleService { public class VehicleServiceImpl extends ServiceImpl<VehicleDao, VehicleEntity> implements VehicleService {
private ErrorMessageComponent errorMessageComponent; private ErrorMessageComponent errorMessageComponent;
......
...@@ -64,6 +64,9 @@ ribbon: ...@@ -64,6 +64,9 @@ ribbon:
eager-load: eager-load:
enabled: true enabled: true
clients: freight-base-service,freight-file-service,freight-app-service clients: freight-base-service,freight-file-service,freight-app-service
font:
windows:
dir: /usr/share/fonts/windows
error-message: error-message:
goodsowner: goodsowner:
account: account:
......
...@@ -64,6 +64,9 @@ ribbon: ...@@ -64,6 +64,9 @@ ribbon:
eager-load: eager-load:
enabled: true enabled: true
clients: freight-base-service,freight-file-service,freight-app-service clients: freight-base-service,freight-file-service,freight-app-service
font:
windows:
dir: /usr/share/fonts/windows
error-message: error-message:
goodsowner: goodsowner:
account: account:
......
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