浏览代码

历史运单接口 ,缺陷修改

mashengyi 1 年之前
父节点
当前提交
76ff3da1c2

二进制
lib/sdk-waybill-protocol-1.5.jar


+ 1 - 1
pom.xml

@@ -304,7 +304,7 @@
             <artifactId>sdk</artifactId>
             <scope>system</scope>
             <version>1.0</version>
-            <systemPath>${project.basedir}/lib/sdk-waybill-protocol-1.5.jar</systemPath>
+            <systemPath>${project.basedir}/lib/sdk-waybill-protocol-1.5.1.jar</systemPath>
         </dependency>
         <!--有车-->
         <dependency>

+ 4 - 4
src/main/java/com/jkcredit/invoice/service/upservice/impl/NoCarInterfaceImpl.java

@@ -164,18 +164,18 @@ public class NoCarInterfaceImpl implements NoCarInterface {
         String fileName = waybillOriginEndRequest.getFilename();
         long startTime = System.currentTimeMillis();
         try {
-            log.info("NoCarInterfaceImpl.waybillOrgEnd请求参数:{}", waybillOriginEndRequest.toString());
+            log.info("NoCarInterfaceImpl.waybillOrgEnd请求参数:{}", StringUtil.removeJSonField(waybillOriginEndRequest.toString(),"base64Str"));
             //(4)指定协议的响应模型(IssuerUploadResponse),调用upload 发送数据
             WaybillOriginEndResponse response = ETCCommHelper.upload(fileName, waybillOriginEndRequest, WaybillOriginEndResponse.class);
-            log.info("NoCarInterfaceImpl.waybillOrgEnd上游接口返回:{},请求参数:{},cost={}ms", response.toString(), waybillOriginEndRequest.toString(), System.currentTimeMillis() - startTime);
+            log.info("NoCarInterfaceImpl.waybillOrgEnd上游接口返回:{},请求参数:{},cost={}ms", response.toString(), StringUtil.removeJSonField(waybillOriginEndRequest.toString(),"base64Str"), System.currentTimeMillis() - startTime);
 
             return new RespR<>(response);
         } catch (IOException e) {
-            log.error(e.getMessage() + " ,请求参数:" + waybillOriginEndRequest.toString() + " ,cost=" + (System.currentTimeMillis() - startTime) + "ms");
+            log.error(e.getMessage() + " ,请求参数:" + StringUtil.removeJSonField(waybillOriginEndRequest.toString(),"base64Str") + " ,cost=" + (System.currentTimeMillis() - startTime) + "ms");
             e.printStackTrace();
             return new RespR(false, "网络异常,请联系管理人员");
         } catch (ApiRequestException apie) {
-            log.error(apie.getMessage().replaceAll("[\r\n]", "") + " ,请求参数:" + waybillOriginEndRequest.toString() + " ,cost=" + (System.currentTimeMillis() - startTime) + "ms");
+            log.error(apie.getMessage().replaceAll("[\r\n]", "") + " ,请求参数:" + StringUtil.removeJSonField(waybillOriginEndRequest.toString(),"base64Str") + " ,cost=" + (System.currentTimeMillis() - startTime) + "ms");
             apie.printStackTrace();
             return new RespR(false, apie.getMessage());
         }

+ 1 - 1
src/main/java/com/jkcredit/invoice/util/LogUtils.java

@@ -163,7 +163,7 @@ public class LogUtils {
     }
 
     public static void main(String[] args) throws Exception {
-        String a = "{\"id_number\":\"36042919960907151X\",\"bank_card_number\":\"6214680048545055\",\"name\":\"刘玺\",\"mobile\":\"15991856264\",\"sign\":\"a93471e386fed0427c68bd6e9967011b\"}";
+        String a = "{\"id_number\":\"36042919960907151X\",\"bank_card_number\":\"6214680048545055\",\"name\":\"刘玺\",\"mobile\":\"13875012909\",\"sign\":\"a93471e386fed0427c68bd6e9967011b\"}";
         System.out.println(encode(a));
         //String b = "{\"sign\":\"a93471e386fed0427c68bd6e9967011b\",\"id_number\":\"NjEyMzIzMTk5MjA5MDg0ODcy\",\"name\":\"5YiY5466\",\"bank_card_number\":\"NjIxNDY4MDA0ODU0NTA1NQ==\",\"mobile\":\"MTU4NzMwNTI4MzY=\"}";
         System.out.println(decode(encode(a)));

+ 1 - 1
src/main/java/com/jkcredit/invoice/util/QueryDemo_3rd.java

@@ -207,7 +207,7 @@ public class QueryDemo_3rd {
          * 具体业务参数放在data中
          */
         JSONObject dataJson = new JSONObject();
-        dataJson.put("num", "1556502455-14");
+        dataJson.put("num", "1556502455-23");
         dataJson.put("plateNumber", "京CF0237");
         dataJson.put("plateColor", 1);
         dataJson.put("startTime", "2023-11-13T19:25:56");

+ 10 - 3
src/main/java/com/jkcredit/invoice/util/QueryDemo_3rd2.java

@@ -5,7 +5,14 @@ import org.apache.commons.httpclient.HttpClient;
 import org.apache.commons.httpclient.NameValuePair;
 import org.apache.commons.httpclient.methods.PostMethod;
 
-import java.io.*;
+import java.io.BufferedReader;
+import java.io.File;
+import java.io.FileInputStream;
+import java.io.FileNotFoundException;
+import java.io.IOException;
+import java.io.InputStream;
+import java.io.InputStreamReader;
+import java.io.LineNumberReader;
 import java.util.HashMap;
 import java.util.Iterator;
 import java.util.regex.Matcher;
@@ -24,7 +31,7 @@ public class QueryDemo_3rd2 {
      */
   //  private static final String appKey = "yqxd";
 
-    static String filename = "/Users/mumuxigua/Downloads/";
+    static String filename = "/Users/mashengyi/Downloads/";
     static String logname = "编辑1.txt";
 
     /**
@@ -62,7 +69,7 @@ public class QueryDemo_3rd2 {
 
                     String appKey = getsrt("appKey:", ":::appSecret:::", str).trim();
                     String appSecret = getsrt(":::appSecret:::", ":::num:::", str).trim();
-                    String num = getsrt(":::num:::\"", "\"", str).trim();
+                    String num = getsrt1(":::num:::",str).trim();
 
                     demo.runMainService(appKey,appSecret,num);
 

+ 1 - 1
src/main/java/com/jkcredit/invoice/util/QueryDemo_3rd3.java

@@ -207,7 +207,7 @@ public class QueryDemo_3rd3 {
          * 具体业务参数放在data中
          */
         JSONObject dataJson = new JSONObject();
-        dataJson.put("num", "1556502455-18");
+        dataJson.put("num", "1556502455-72");
         dataJson.put("plateNumber", "京CF0237");
         dataJson.put("plateColor", 1);
         dataJson.put("startTime", "2023-09-13T19:25:56");

+ 5 - 7
src/main/java/com/jkcredit/invoice/util/QueryDemo_Test1.java

@@ -40,7 +40,7 @@ public class QueryDemo_Test1 {
 	 */
 	 	//private static final String appKey = "junxin_test";
 	
-		private static final String appKey = "jkxy";
+		private static final String appKey = "wycl";
 	 	//private static final String appKey = "ccx";
 
 	/**
@@ -62,9 +62,7 @@ public class QueryDemo_Test1 {
 			 * 实名demo
 			 */
 			String [] nums = {
-					"KHY921000470609055744",
-					"",
-
+					"20230228090318885_868_27_245"
 			};
 			for(int i=0;i<nums.length;i++){
 //				JSONObject paramJsonObj202109 = initParamJsonObj_Realname202109(nums[i]);
@@ -440,7 +438,7 @@ public class QueryDemo_Test1 {
 		//paramJsonObj.put("api", "MSISDNMD5TOIMEI");//MOBILE_CHECK_V1//CMCC_3RD_VERIFY_V4//CTCC_CHECK_V1
 		paramJsonObj.put("appKey", appKey);
 		paramJsonObj.put("appSecret",
-				"7697CE9BB9D5A856CFDDE738320AD34EA53E483C");
+				"8EDEE739B81EFF37820A1921DEFC0ABE39FF137A");
 		//"84C1CE24EDF361F28072E313BD87EAB24CC727CF");
 
 
@@ -449,8 +447,8 @@ public class QueryDemo_Test1 {
 		 * 业务参数
 		 */
 		JSONObject dataJson = new JSONObject();
-		dataJson.put("plateNumber","川AD58376");
-		dataJson.put("plateColor","9");
+		dataJson.put("plateNumber","豫HJ8510");
+		dataJson.put("plateColor","1");
 		paramJsonObj.put("data", dataJson);
 		return paramJsonObj;
 	}