JLChen
2020-06-05 f86c8b5dcf5c84386745b009fc4115fa9db3b76d
2020-06-05 1.修复消息报警页面,调用清空消息接口失败问题。
5个文件已修改
37 ■■■■ 已修改文件
SmartHome/ON/Properties/AndroidManifest.xml 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
SmartHome/SmartHome/HDL/Operation/RemoteInfo.cs 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SmartHome/SmartHome/Net/API.cs 8 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SmartHome/SmartHome/UI/SimpleControl/MainPage.cs 6 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SmartHome/SmartHome/UI/SimpleControl/Phone/Warning/WarningList.cs 15 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SmartHome/ON/Properties/AndroidManifest.xml
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android" android:versionCode="2020060201" android:versionName="2.506021" package="com.hdl.in">
<manifest xmlns:android="http://schemas.android.com/apk/res/android" android:versionCode="2020060501" android:versionName="2.506051" package="com.hdl.in">
    <uses-sdk android:minSdkVersion="23" android:targetSdkVersion="26" />
    <!--Ezviz 权限 -->
    <uses-permission android:name="android.permission.FLASHLIGHT" />
SmartHome/SmartHome/HDL/Operation/RemoteInfo.cs
@@ -34,9 +34,9 @@
                    if (revertObj.StateCode == "SUCCESS") {
                        var msgList = Newtonsoft.Json.JsonConvert.DeserializeObject<List<RemoteInfoMsg>> (revertObj.ResponseData.ToString ());
                        //清楚角标
                        new WebClient().DownloadData ($"https://global.hdlcontrol.com/HangZhouHdlCloudApi/ZigbeeUsers/CornerClear");
                        //
                        ////清楚角标 2020-06-05 高胜说云端已自动清空,不需要调用
                        //new WebClient().DownloadData ($"https://global.hdlcontrol.com/HangZhouHdlCloudApi/ZigbeeUsers/CornerClear");
                        if (msgList == null || msgList.Count == 0)
                            return;
                        if (msgList.Count == Current.RemoteInfoList.Count && msgList [msgList.Count - 1].MsgTime == Current.RemoteInfoList [Current.RemoteInfoList.Count - 1].MsgTime)
SmartHome/SmartHome/Net/API.cs
@@ -220,5 +220,13 @@
    }
    /// <summary>
    /// 推送TokenID
    /// </summary>
    public class RegIDObj
    {
        public string RegID;
    }
    #endregion
}
SmartHome/SmartHome/UI/SimpleControl/MainPage.cs
@@ -48,9 +48,9 @@
        public static string sendTime = "";
        public static string recTime = "";
#if wallon
        public static string CodeIDString = "202006021";
        public static string CodeIDString = "202006051";
#else
        public static string CodeIDString = "2.506021";
        public static string CodeIDString = "2.506051";
#endif
        public static UserInfo LoginUser;
        public static string RequestSource = "1"; //0:Zigbee、1:HdlOn、2:GraphicsMonitor、3:BusproSoft、4:AgentWeb
@@ -318,6 +318,8 @@
        public static bool checeInternet ()
        {
            return true;
            byte [] bytes = null;
            var dateTime = DateTime.Now;
            System.Threading.Tasks.Task.Run (() => {
SmartHome/SmartHome/UI/SimpleControl/Phone/Warning/WarningList.cs
@@ -152,10 +152,17 @@
                alert.ResultEventHandler += (sender1, e1) => {
                    if (e1) {
                        System.Threading.Tasks.Task.Factory.StartNew (() => {
                            string jsonString = "{" +
                                              "\"RegID\":" + "\"" + UserConfig.Instance.tokenID + "\"" + "," +
                                                   "}";
                            var revertObj = MainPage.RequestHttps ($"https://global.hdlcontrol.com/HangZhouHdlCloudApi/ZigbeeUsers/ClearMessage", jsonString, true);
                            //string jsonString = "{" +
                            //                  "\"RegID\":" + "\"" + UserConfig.Instance.tokenID + "\"" + "," +
                            //                       "}";
                            //var revertObj = MainPage.RequestHttps ($"https://global.hdlcontrol.com/HangZhouHdlCloudApi/ZigbeeUsers/ClearMessage", jsonString, true);
                            //2020-06-05 修复消息报警页面,调用清空消息接口失败问题。
                            var mRegIDObj = new RegIDObj () {
                                RegID = UserConfig.Instance.tokenID,
                            };
                            var jsonString = Newtonsoft.Json.JsonConvert.SerializeObject (mRegIDObj);
                            var revertObj = MainPage.RequestHttps (@"ClearMessage", jsonString, true, false);
                        });
                        RemoteInfo.Current.CleanAll ();
                        ShowWarningListPage ();