From 29160efe0f203c5e65dcf4e5a429ced6bde39187 Mon Sep 17 00:00:00 2001
From: mac <user@users-MacBook-Pro.local>
Date: 星期二, 29 八月 2023 15:35:24 +0800
Subject: [PATCH] 2023年08月29日15:35:09
---
HDL-ON_Android/HDL-ON_Android.csproj | 3 ++-
HDL_ON/UI/UI2/FuntionControlView/HisenseTV /Send.cs | 9 +++++----
HDL_ON/DAL/Server/NewAPI.cs | 2 +-
HDL_ON/Entity/Function/Function.cs | 8 +++++---
HDL_ON/DAL/Server/HttpUtil.cs | 4 ++--
HDL_ON/UI/UI2/FuntionControlView/HisenseTV /HisenseTvPage.cs | 6 ++++--
6 files changed, 19 insertions(+), 13 deletions(-)
diff --git a/HDL-ON_Android/HDL-ON_Android.csproj b/HDL-ON_Android/HDL-ON_Android.csproj
index 5a949f0..1bbff4c 100644
--- a/HDL-ON_Android/HDL-ON_Android.csproj
+++ b/HDL-ON_Android/HDL-ON_Android.csproj
@@ -23,7 +23,7 @@
<MonoAndroidAssetsPrefix>Assets</MonoAndroidAssetsPrefix>
<AndroidEnableSGenConcurrent>true</AndroidEnableSGenConcurrent>
<AndroidUseAapt2>true</AndroidUseAapt2>
- <AndroidSupportedAbis>armeabi-v7a</AndroidSupportedAbis>
+ <AndroidSupportedAbis>arm64-v8a</AndroidSupportedAbis>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>True</DebugSymbols>
@@ -47,6 +47,7 @@
<AndroidEnableMultiDex>false</AndroidEnableMultiDex>
<AndroidUseAapt2>true</AndroidUseAapt2>
<EmbedAssembliesIntoApk>true</EmbedAssembliesIntoApk>
+ <AndroidSupportedAbis>arm64-v8a;armeabi-v7a</AndroidSupportedAbis>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<DebugSymbols>True</DebugSymbols>
diff --git a/HDL_ON/DAL/Server/HttpUtil.cs b/HDL_ON/DAL/Server/HttpUtil.cs
index 5235064..b659327 100644
--- a/HDL_ON/DAL/Server/HttpUtil.cs
+++ b/HDL_ON/DAL/Server/HttpUtil.cs
@@ -18,8 +18,8 @@
/// 鍥哄畾鍩熷悕,姝e紡鐜
/// 鍏叡鍩熷悕灏辫繎瑙f瀽
/// </summary>
- public const string GlobalRequestHttpsHost = "https://nearest.hdlcontrol.com";
- //public const string GlobalRequestHttpsHost = "https://test-gz.hdlcontrol.com";
+ //public const string GlobalRequestHttpsHost = "https://nearest.hdlcontrol.com";
+ public const string GlobalRequestHttpsHost = "https://test-gz.hdlcontrol.com";
const string APP_KEY = "HDL-HOME-APP-TEST";
const string SECRET_KEY = "WeJ8TY88vbakCcnvH8G1tDUqzLWY8yss";
diff --git a/HDL_ON/DAL/Server/NewAPI.cs b/HDL_ON/DAL/Server/NewAPI.cs
index 2555660..fbbad8b 100644
--- a/HDL_ON/DAL/Server/NewAPI.cs
+++ b/HDL_ON/DAL/Server/NewAPI.cs
@@ -760,7 +760,7 @@
/// <summary>
/// 瑙g粦浣忓畢涓嬬殑绗笁鏂硅澶�
/// </summary>
- public const string Api_Post_UnbindDeviceToHome = "/smart-open/open-platform/tripartite/unbindDeviceToHome";
+ public const string Api_Post_UnbindDeviceToHome = "/home-wisdom/app/open/unbindDeviceToHome";
#endregion
diff --git a/HDL_ON/Entity/Function/Function.cs b/HDL_ON/Entity/Function/Function.cs
index 2ef2075..7c2aee2 100644
--- a/HDL_ON/Entity/Function/Function.cs
+++ b/HDL_ON/Entity/Function/Function.cs
@@ -108,6 +108,7 @@
/// 鑾峰彇灞炴�у綋鍓嶇姸鎬�
/// </summary>
/// <param name="key"></param>
+ /// <param name="defaultValue">榛樿鍊�</param>
/// <returns></returns>
public string GetAttrState(string key, string defaultValue = "0")
{
@@ -120,7 +121,7 @@
if (string.IsNullOrEmpty(attrState.state))
{
//浜岀骇鏌ヨkeyValue鍊�
- return GetOriginalState(key);
+ return GetOriginalState(key, defaultValue);
}
return attrState.state;
}
@@ -130,13 +131,14 @@
/// 榛樿鍊硷細0
/// </summary>
/// <param name="key">璇泙瀹氫箟鐨勫睘鎬у��</param>
+ /// <param name="defaultValue">榛樿鍊�</param>
/// <returns></returns>
- public string GetOriginalState(string key)
+ public string GetOriginalState(string key, string defaultValue)
{
var originalState = status.Find((s) => s.key == key.ToString());
if (originalState == null || string.IsNullOrEmpty(originalState.value))
{
- return "0";
+ return defaultValue;
}
return originalState.value;
}
diff --git a/HDL_ON/UI/UI2/FuntionControlView/HisenseTV /HisenseTvPage.cs b/HDL_ON/UI/UI2/FuntionControlView/HisenseTV /HisenseTvPage.cs
index e939fda..56214c5 100644
--- a/HDL_ON/UI/UI2/FuntionControlView/HisenseTV /HisenseTvPage.cs
+++ b/HDL_ON/UI/UI2/FuntionControlView/HisenseTV /HisenseTvPage.cs
@@ -288,9 +288,11 @@
});
//淇″彿婧�
- sourceFrameLayout.selectAction += (text) =>
+ sourceFrameLayout.selectAction += (key) =>
{
- string value = text.Replace(" ", "_");
+ var p = new UI2.Intelligence.Automation.PublicInterface();
+ var dic = p.GetHisenseSignalSourceDic();
+ string value = p.GetValue(dic, key);
ControlCommand(HisenseTVFunctionalAttributeConstant.signal, value);
};
diff --git a/HDL_ON/UI/UI2/FuntionControlView/HisenseTV /Send.cs b/HDL_ON/UI/UI2/FuntionControlView/HisenseTV /Send.cs
index 875d3ad..9f0a66a 100644
--- a/HDL_ON/UI/UI2/FuntionControlView/HisenseTV /Send.cs
+++ b/HDL_ON/UI/UI2/FuntionControlView/HisenseTV /Send.cs
@@ -43,7 +43,8 @@
var responsePackNew = UI.Music.SendMethod.Current.RequestServerhomeId(d, NewAPI.Api_Post_UnbindDeviceToHome, "鍒犻櫎娴蜂俊鐢佃");
if (!this.DataChecking(responsePackNew, tipType))
{
- action?.Invoke(false);
+ //action?.Invoke(false);
+ return;
}
action?.Invoke(true);
}
@@ -51,13 +52,13 @@
/// <summary>
/// 鍙戦�佹帶鍒跺懡浠�
/// </summary>
- /// <param name="function">褰撳墠璁惧</param>
+ /// <param name="device">褰撳墠璁惧</param>
/// <param name="dic">鍙戦�佹帶鍒舵暟鎹�</param>
- public void SendControlCommand(Function function, Dictionary<string, string> dic,Action<bool> action)
+ public void SendControlCommand(Function device, Dictionary<string, string> dic,Action<bool> action)
{
new System.Threading.Thread(() =>
{
- var result = DriverLayer.Control.Ins.SendWriteCommand(function, dic, false, 0);
+ var result = DriverLayer.Control.Ins.SendWriteCommand(device, dic, false, 0);
action?.Invoke(result);
})
--
Gitblit v1.8.0