diff --git a/CPF_Cef/MainModel.cs b/CPF_Cef/MainModel.cs index 82da99b..dc575b5 100644 --- a/CPF_Cef/MainModel.cs +++ b/CPF_Cef/MainModel.cs @@ -1676,14 +1676,14 @@ namespace AksWebBrowser { return "{\"timestamp\":\"" + Utils.GetTimestamp() + "\",\"keycode\":\"" + "" + "\",\"message\":\"Falied\",\"code\":\"400\",\"status\":false,\"data\":\"" + "参数解析错误" + "\"}"; } - string faceA = Utils.Base64ByImagesPath(param.faceA, "faceA"); - string faceB = Utils.Base64ByImagesPath(param.faceB, "faceB"); + string faceA = Utils.Base64ByImagesPath(param.faceA.Replace("data:image/jpg;base64,",""), "faceA"); + string faceB = Utils.Base64ByImagesPath(param.faceB.Replace("data:image/jpg;base64,",""), "faceB"); var mode2 = new { filePathA = faceA, filePathB = faceB }; - return "{\"timestamp\":\"" + Utils.GetTimestamp() + "\",\"keycode\":\"" + param.code + "\",\"message\":\"seccse\",\"code\":\"200\",\"status\":true,\"data\":\"" + JsonConvert.SerializeObject(mode2) + "\"}"; + return "{\"timestamp\":\"" + Utils.GetTimestamp() + "\",\"keycode\":\"" + param.code + "\",\"message\":\"seccse\",\"code\":\"200\",\"status\":true,\"data\":" + JsonConvert.SerializeObject(mode2) + "}"; } catch (Exception ex) { diff --git a/CPF_Cef/Parame.cs b/CPF_Cef/Parame.cs index e5aef54..bd57d4d 100644 --- a/CPF_Cef/Parame.cs +++ b/CPF_Cef/Parame.cs @@ -22,7 +22,7 @@ namespace AksWebBrowser public static WebSocketClientWithHeartbeat webSocket2 { get; set; } public static List FuncObject { get; set; } //接口地址 - public static string apiUrl = "http://192.168.0.234:8098";//"http://143.169.62.3:8098";// + public static string apiUrl ="http://127.0.0.1:8098";//"http://143.169.62.3:8098";// //授权key public static string key = "1"; //硬件Ip @@ -42,7 +42,7 @@ namespace AksWebBrowser //波特率 public static int pritPjPort = 38400; //打印名字 - public static string PrinterName = "Lexmark-MS430-Series"; + public static string PrinterName = "Lexmark-CS430-Series"; //是否启用双目 public static bool isSM = true; //是否开启高拍仪