From 38ca58ae790dc71e50070b54345455988a4a64a3 Mon Sep 17 00:00:00 2001
From: JLChen <551775569@qq.com>
Date: 星期五, 27 八月 2021 11:24:52 +0800
Subject: [PATCH] 2021-8-27-01
---
HDL_ON/UI/UI2/4-PersonalCenter/PirDevice/PirSend.cs | 31 ++++++++++++++++++++++++-------
1 files changed, 24 insertions(+), 7 deletions(-)
diff --git a/HDL_ON/UI/UI2/4-PersonalCenter/PirDevice/PirSend.cs b/HDL_ON/UI/UI2/4-PersonalCenter/PirDevice/PirSend.cs
index 957fb02..6f4b31f 100644
--- a/HDL_ON/UI/UI2/4-PersonalCenter/PirDevice/PirSend.cs
+++ b/HDL_ON/UI/UI2/4-PersonalCenter/PirDevice/PirSend.cs
@@ -33,9 +33,16 @@
{
get
{
- return Entity.DB_ResidenceData.Instance.CurrentRegion.RegionID;
+ return Entity.DB_ResidenceData.Instance.CurrentRegion.id;
}
}
+
+
+ /// <summary>
+ /// 涔愭subAccessToken
+ /// </summary>
+ public static string LcSubAccessToken = "";
+
/// <summary>
/// 鏄惁涓哄叾浠栦富鐢ㄦ埛鍒嗕韩杩囨潵鐨勪綇瀹�
/// </summary>
@@ -43,7 +50,7 @@
{
get
{
- return Entity.DB_ResidenceData.Instance.CurrentRegion.IsOthreShare;
+ return Entity.DB_ResidenceData.Instance.CurrentRegion.isOtherShare;
}
}
/// <summary>
@@ -150,7 +157,7 @@
/// 绾㈠鐮佸涔�
/// </summary>
/// <returns></returns>
- public static void CodeStudy(Control control,AttributesStatus buttonObj,Action<ResponsePackNew> action)
+ public static void CodeStudy(Control control, AttributesStatus buttonObj, Action<Cloud> action)
{
var job = new JObject { };
job.Add("key", buttonObj.key);
@@ -161,21 +168,32 @@
var jArray = new JArray { };
jArray.Add(job);
var jObject = new JObject { { "homeId", HomeId }, { "deviceId", control.deviceId }, { "attributes", jArray } };
- ResponsePackNew responsePackNew = null;
+ Cloud cloud = null;
new System.Threading.Thread(() =>
{
try
{
//鍙戦�佺孩澶栫爜瀛︿範鍛戒护
- responsePackNew = RequestServerhomeId(jObject, NewAPI.API_POST_Ir_CodeStudy);
+ var responsePackNew = RequestServerhomeId(jObject, NewAPI.API_POST_Ir_CodeStudy);
+ if (responsePackNew != null && responsePackNew.Code == "0" && responsePackNew.Data.ToString() != "")
+ {
+ PirMethod method = new PirMethod();
+ PirMethod.buttondata = "";
+ cloud = method.MqttDate("鎸夐敭", control.sid, 25);
+ }
+ else
+ {
+ PirMethod method = new PirMethod();
+ method.ErrorShow(responsePackNew, "");
+ }
}
catch { }
finally
{
Application.RunOnMainThread(() =>
{
- action(responsePackNew);
+ action(cloud);
});
}
@@ -267,7 +285,6 @@
{ IsBackground = true }.Start();
}
-
/// <summary>
///璇锋眰鏈嶅姟鍣紙涓庝綇瀹呮湁鍏�:渚嬪锛沨omeId锛�
/// </summary>
--
Gitblit v1.8.0