|
|
@ -13,6 +13,7 @@ using AKSWebBrowser.Commen; |
|
|
|
using System.Collections; |
|
|
|
using System.Collections; |
|
|
|
using System.Net.NetworkInformation; |
|
|
|
using System.Net.NetworkInformation; |
|
|
|
using AKS.EnterpriseLibrary.WebBrowser; |
|
|
|
using AKS.EnterpriseLibrary.WebBrowser; |
|
|
|
|
|
|
|
using System.Globalization; |
|
|
|
|
|
|
|
|
|
|
|
namespace AksWebBrowser.Common |
|
|
|
namespace AksWebBrowser.Common |
|
|
|
{ |
|
|
|
{ |
|
|
@ -125,10 +126,30 @@ namespace AksWebBrowser.Common |
|
|
|
JObject jo4 = (JObject)JsonConvert.DeserializeObject(parameters); |
|
|
|
JObject jo4 = (JObject)JsonConvert.DeserializeObject(parameters); |
|
|
|
//读取签字base64 |
|
|
|
//读取签字base64 |
|
|
|
string sign_pic = jo4["sign_pic"].ToString(); |
|
|
|
string sign_pic = jo4["sign_pic"].ToString(); |
|
|
|
|
|
|
|
string time = DateTime.Now.ToString("yyyyMMddHHmmss", DateTimeFormatInfo.InvariantInfo); |
|
|
|
|
|
|
|
string dirpath = Utils.getSystemPaht() + @"/wwwroot/FileTxt"; |
|
|
|
|
|
|
|
if (!Directory.Exists(dirpath)) |
|
|
|
|
|
|
|
{ |
|
|
|
|
|
|
|
Directory.CreateDirectory(dirpath); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
var tempFile = dirpath + "/" + time + ".txt"; |
|
|
|
|
|
|
|
using (StreamWriter sw = new StreamWriter(tempFile)) |
|
|
|
|
|
|
|
{ |
|
|
|
|
|
|
|
sw.Write(sign_pic); |
|
|
|
|
|
|
|
sw.Close(); |
|
|
|
|
|
|
|
sw.Dispose(); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
string base64 = ""; |
|
|
|
|
|
|
|
string[] lines = File.ReadAllLines(tempFile); |
|
|
|
|
|
|
|
foreach (string line in lines) |
|
|
|
|
|
|
|
{ |
|
|
|
|
|
|
|
base64= base64+line; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
File.Delete(tempFile); |
|
|
|
//读取签字版主动回复数据 |
|
|
|
//读取签字版主动回复数据 |
|
|
|
//"data:image/png;base64, " + |
|
|
|
//"data:image/png;base64, " + |
|
|
|
Log.Info("读取签字版主动回复数据" + sign_pic); |
|
|
|
Log.Info("读取签字版主动回复数据" + base64); |
|
|
|
return "{\"keycode\":\"" + code + "\",\"message\":\"success\",\"code\":\"200\",\"status\":true,\"suffix\":\"png\",\"data\":\"" + sign_pic + "\"}"; |
|
|
|
return "{\"keycode\":\"" + code + "\",\"message\":\"success\",\"code\":\"200\",\"status\":true,\"suffix\":\"png\",\"data\":\"" + base64 + "\"}"; |
|
|
|
} |
|
|
|
} |
|
|
|
else |
|
|
|
else |
|
|
|
{ |
|
|
|
{ |
|
|
|