HDL Home App 第二版本 旧平台金堂用 正在使用
黄学彪
2019-10-15 2bf5ec775cb57d8015bee58c745a1e48081ff1b1
ZigbeeApp/Shared/Phone/Device/Logic/LogicIfon.cs
@@ -1,5 +1,6 @@
using System;
using System.Collections.Generic;
using Shared;
namespace Shared.Phone.Device.Logic
{
    public class LogicIfon
@@ -80,7 +81,7 @@
        {
            for (int i = 0; i < Common.Logic.CurrentLogic.Conditions.Count; i++)
            {
                if (Common.Logic.CurrentLogic.Conditions[i]["Type"] == "7")
                if (Common.Logic.CurrentLogic.Conditions[i]["Type"] == objecttype["Type"])
                {
                    Common.Logic.CurrentLogic.Conditions.RemoveAt(i);
@@ -181,6 +182,25 @@
        }
        #endregion
        #region ----关联app账号----
        /// <summary>
        /// 关联app账号
        /// </summary>
        /// <param name="accountsInfo"></param>
        public static void Addaccounts(Dictionary<string, string> accountsInfo)
        {
            for (int i = 0; i < Common.Logic.CurrentLogic.Accounts.Count; i++)
            {
                if (Common.Logic.CurrentLogic.Accounts[i]["Type"] == accountsInfo["Type"])
                {
                    Common.Logic.CurrentLogic.Accounts.RemoveAt(i);
                    Common.Logic.CurrentLogic.Accounts.Insert(i, accountsInfo);
                    return;
                }
            }
            Common.Logic.CurrentLogic.Accounts.Add(accountsInfo);
        }
        #endregion
    }