feature: 发票列表查询

jianshui-ui
xingze 1 year ago
parent 7c8db6887e
commit 30bd130115
  1. 18
      jianshui-invoice/src/main/java/com/jianshui/invoice/utils/elephant/ElephantUtils.java

@ -369,7 +369,7 @@ public class ElephantUtils {
*/ */
public static DxhyInterfaceResponse sendRequestWithoutTokenV6(String uri, String methodName, JSON data, Companyservice companyservice) throws UnsupportedEncodingException, NoSuchAlgorithmException, InvalidKeyException { public static DxhyInterfaceResponse sendRequestWithoutTokenV6(String uri, String methodName, JSON data, Companyservice companyservice) throws UnsupportedEncodingException, NoSuchAlgorithmException, InvalidKeyException {
/*ICompanyservicePropService companyserviceProp = SpringUtils.getBean(ICompanyservicePropService.class); ICompanyservicePropService companyserviceProp = SpringUtils.getBean(ICompanyservicePropService.class);
CompanyserviceProp secretIdProp = companyserviceProp.selectPropByKey(companyservice.getCompanyid(), "elephant_secret_id"); CompanyserviceProp secretIdProp = companyserviceProp.selectPropByKey(companyservice.getCompanyid(), "elephant_secret_id");
if (secretIdProp == null) { if (secretIdProp == null) {
throw new JianshuiServiceException("企业未配置属性,请联系管理员!"); throw new JianshuiServiceException("企业未配置属性,请联系管理员!");
@ -386,20 +386,20 @@ public class ElephantUtils {
String str = JSONUtil.toJsonStr(data); String str = JSONUtil.toJsonStr(data);
boolean isDevMode = CommonUtils.isDevMode(); boolean isDevMode = CommonUtils.isDevMode();
// 主机名(京东云地址) // 主机名(京东云地址)
*//*String host = ElephantConstants.PROD_HOST_LOCAL_V6_JingDongYun; /*String host = ElephantConstants.PROD_HOST_LOCAL_V6_JingDongYun;
if (isDevMode) { if (isDevMode) {
host = ElephantConstants.DEV_HOST_LOCAL_V6_JingDongYun; host = ElephantConstants.DEV_HOST_LOCAL_V6_JingDongYun;
}*//* }*/
String host = ELE_URL_v6; String host = ELE_URL_v6;
// 最终接口地址 // 最终接口地址
String url = host + uri;*/ String url = host + uri;
// 封装大象v6调用类 // 封装大象v6调用类
DxhyInterfaceRequest dxhyInterfaceRequest = new DxhyInterfaceRequest(); DxhyInterfaceRequest dxhyInterfaceRequest = new DxhyInterfaceRequest();
// 地址 // 地址
dxhyInterfaceRequest.setRequestUrl("http://192.168.3.169:10000/sims-api/invoice/api/v6/QueryInvoiceList"); dxhyInterfaceRequest.setRequestUrl(url);
// 请求方式 // 请求方式
dxhyInterfaceRequest.setRequestType("POST"); dxhyInterfaceRequest.setRequestType("POST");
// 超时时间(毫秒值) // 超时时间(毫秒值)
@ -413,11 +413,11 @@ public class ElephantUtils {
dxhyInterfaceRequest.setDataExchangeId(snowflakeIdStr); dxhyInterfaceRequest.setDataExchangeId(snowflakeIdStr);
// appid // appid
dxhyInterfaceRequest.setSecretId("JJVUXH8eYxXeQgeU5PrEPlPUsGCpF0Ln"); dxhyInterfaceRequest.setSecretId(secretId);
// appkey // appkey
dxhyInterfaceRequest.setSecretKey("UFvypbPSU51iwMdDoyPe8yWpt2PvxaHbgu3c"); dxhyInterfaceRequest.setSecretKey(sercretKey);
// 内容字段(content请求体) // 内容字段(content请求体)
dxhyInterfaceRequest.setContent(JSONUtil.toJsonStr(data)); dxhyInterfaceRequest.setContent(str);
// 不打包 // 不打包
dxhyInterfaceRequest.setZipCode("0"); dxhyInterfaceRequest.setZipCode("0");
// 不加密 // 不加密
@ -434,7 +434,7 @@ public class ElephantUtils {
} catch (Exception e) { } catch (Exception e) {
log.error("【销项】【大象接口】调用HttpsUtilV6.Exception, url=" + "url" + ",request=" + JSONUtil.toJsonStr(dxhyInterfaceRequest), e); log.error("【销项】【大象接口】调用HttpsUtilV6.Exception, url=" + url + ",request=" + JSONUtil.toJsonStr(dxhyInterfaceRequest), e);
} }
return dxhyInterfaceResponse; return dxhyInterfaceResponse;

Loading…
Cancel
Save