|
@@ -568,6 +568,30 @@ namespace MySystem
|
|
|
string result = function.PostWebRequest(SftReqUrl + "batchUpdateSnPolicyNo", Newtonsoft.Json.JsonConvert.SerializeObject(req), "application/json");
|
|
|
return result;
|
|
|
}
|
|
|
+ public string SftSnBindOrUnbind(string snNo, string merchantId)
|
|
|
+ {
|
|
|
+ Dictionary<string, object> req = new Dictionary<string, object>();
|
|
|
+ req.Add("orgPromoterId", OrgId);
|
|
|
+ req.Add("promoterId", OrgId);
|
|
|
+ req.Add("merchantId", merchantId);
|
|
|
+ req.Add("terminalId", snNo);
|
|
|
+ req.Add("sn", snNo);
|
|
|
+ req.Add("hasServiceFee", "0");
|
|
|
+ req.Add("signType", "RSA");
|
|
|
+ req.Add("charType", "UTF-8");
|
|
|
+ req.Add("requestId", DateTime.Now.ToString("yyyyMMddHHmmssfff") + function.get_Random(8));
|
|
|
+ req.Add("requestTime", function.GetCurTimestamp());
|
|
|
+ req = req.OrderBy(m => m.Key).ToDictionary(m => m.Key, m => m.Value);
|
|
|
+ string signString = "";
|
|
|
+ foreach (string key in req.Keys)
|
|
|
+ {
|
|
|
+ signString += key + "=" + req[key].ToString() + "&";
|
|
|
+ }
|
|
|
+ signString = signString.TrimEnd('&');
|
|
|
+ req.Add("mac", SftEncrypt(signString));
|
|
|
+ string result = function.PostWebRequest(SftReqUrl + "batchUpdateSnPolicyNo", Newtonsoft.Json.JsonConvert.SerializeObject(req), "application/json");
|
|
|
+ return result;
|
|
|
+ }
|
|
|
|
|
|
#endregion
|
|
|
|