|
@@ -2709,7 +2709,7 @@ namespace MOKA_Factory_Tools
|
|
|
#endregion
|
|
|
|
|
|
#region 小米FireTV功能模块相关接口;
|
|
|
- public static bool GetMIKey(string sn, out MIKey mikey, out string msg)
|
|
|
+ public static bool GetMIKey(string url, string sn, out MIKey mikey, out string msg)
|
|
|
{
|
|
|
msg = "";
|
|
|
mikey = new MIKey();
|
|
@@ -2723,11 +2723,7 @@ namespace MOKA_Factory_Tools
|
|
|
KeepAlive = false
|
|
|
};
|
|
|
|
|
|
-#if DEBUG
|
|
|
- item.URL = "http://10.126.124.85:9306/api/SMESCustomer/GetXMCard";
|
|
|
-#else
|
|
|
- item.URL = "http://smes-app-prod.tclking.com:9006/api/SMESCustomer/GetXMCard";
|
|
|
-#endif
|
|
|
+ item.URL = url;
|
|
|
item.Postdata = strPost;
|
|
|
HttpResult hResult = http.GetHtml(item);
|
|
|
if (hResult.StatusCode == System.Net.HttpStatusCode.OK)
|
|
@@ -2776,7 +2772,7 @@ namespace MOKA_Factory_Tools
|
|
|
return false;
|
|
|
}
|
|
|
|
|
|
- public static bool ReportMIKey(ReportMIKey mikey, out string msg)
|
|
|
+ public static bool ReportMIKey(string url, ReportMIKey mikey, out string msg)
|
|
|
{
|
|
|
msg = "";
|
|
|
HttpHelper http = new HttpHelper();
|
|
@@ -2788,11 +2784,7 @@ namespace MOKA_Factory_Tools
|
|
|
KeepAlive = false
|
|
|
};
|
|
|
|
|
|
-#if DEBUG
|
|
|
- item.URL = "http://10.126.124.85:9306/api/SMESCustomer/UploadXMDataControl";
|
|
|
-#else
|
|
|
- item.URL = "http://smes-app-prod.tclking.com:9006/api/SMESCustomer/UploadXMDataControl";
|
|
|
-#endif
|
|
|
+ item.URL = url;
|
|
|
item.Postdata = JsonConvert.SerializeObject(mikey); ;
|
|
|
HttpResult hResult = http.GetHtml(item);
|
|
|
if (hResult.StatusCode == System.Net.HttpStatusCode.OK)
|
|
@@ -2830,8 +2822,7 @@ namespace MOKA_Factory_Tools
|
|
|
|
|
|
return false;
|
|
|
}
|
|
|
-
|
|
|
-#endregion
|
|
|
+ #endregion
|
|
|
}
|
|
|
|
|
|
/// <summary>
|