From 3d5d2cb6bc250b15bec6c1fa233b69a1ff1ea050 Mon Sep 17 00:00:00 2001
From: wjc <1243177876@qq.com>
Date: 星期三, 29 三月 2023 19:02:29 +0800
Subject: [PATCH] 2023年03月29日19:02:18
---
HDL_ON/UI/UI2/FuntionControlView/VideoDoorLock/CommonMethod.cs | 31 +++++++++++++++++++++++++++++++
HDL_ON/Common/HDLCommon.cs | 6 ++++--
HDL_ON/UI/UI2/FuntionControlView/VideoDoorLock/VideoDoorLockPage.cs | 22 ++++++++++++++++++++++
3 files changed, 57 insertions(+), 2 deletions(-)
diff --git a/HDL_ON/Common/HDLCommon.cs b/HDL_ON/Common/HDLCommon.cs
index 1baaed0..1e5d28d 100644
--- a/HDL_ON/Common/HDLCommon.cs
+++ b/HDL_ON/Common/HDLCommon.cs
@@ -275,8 +275,10 @@
//鎶ヨ鎺ㄩ�佹墠寮圭獥鎻愮ず锛坢essageType鍖呭惈Alarm鍏抽敭瀛楃殑锛�
if (jpushMessageInfo.messageType.Contains(PushMessageType.Alarm.ToString()))
{
- //鎶ヨ鎺ㄩ�佸脊绐楁彁绀�
- ShowAlarmPushMessage(jpushMessageInfo, true);
+ //钀ょ煶闂ㄩ攣鏇存柊寮�閿佸浘鏍�
+ HDL_ON.UI.UI2.FuntionControlView.VideoDoorLock.CommonMethod.Current.UpdateDoorLockState(PushMessageType.Alarm, jpushMessageInfo.HomeId, jpushMessageInfo.spk, jpushMessageInfo.Extras);
+ //鎶ヨ鎺ㄩ�佸脊绐楁彁绀�
+ ShowAlarmPushMessage(jpushMessageInfo, true);
}
else if (jpushMessageInfo.messageType.Contains(PushMessageType.FLCall.ToString()))
{
diff --git a/HDL_ON/UI/UI2/FuntionControlView/VideoDoorLock/CommonMethod.cs b/HDL_ON/UI/UI2/FuntionControlView/VideoDoorLock/CommonMethod.cs
index 0af7600..1d9736b 100644
--- a/HDL_ON/UI/UI2/FuntionControlView/VideoDoorLock/CommonMethod.cs
+++ b/HDL_ON/UI/UI2/FuntionControlView/VideoDoorLock/CommonMethod.cs
@@ -292,6 +292,37 @@
#endif
return list;
}
+
+ /// <summary>
+ /// 鏇存柊寮�閿佸浘鏍囧拰鐢垫睜鐘舵��
+ /// </summary>
+ public void UpdateDoorLockState(PushMessageType pushMessageType, string homeId, string spk, string stateContent)
+ {
+ if (spk != SPK.VideoDoorLock)
+ {
+ return;
+ }
+ this.MainThread(() =>
+ {
+ int childrenCount = MainPage.BasePageView.ChildrenCount - 1;
+ for (int i = childrenCount; childrenCount > i; i--)
+ {
+ View view = MainPage.BasePageView.GetChildren(i);
+ if (view is VideoDoorLockPage)
+ {
+ VideoDoorLockPage videoDoorLockPage = (VideoDoorLockPage)view;
+ if (videoDoorLockPage != null)
+ {
+ videoDoorLockPage.UpdateState(pushMessageType);
+ }
+
+ }
+ }
+ });
+
+ }
+
+
#region --------- 鍔熻兘鏂囦欢淇濆瓨锛屽垹闄� --------
/// <summary>
/// 淇濆瓨鏈湴鏂囦欢
diff --git a/HDL_ON/UI/UI2/FuntionControlView/VideoDoorLock/VideoDoorLockPage.cs b/HDL_ON/UI/UI2/FuntionControlView/VideoDoorLock/VideoDoorLockPage.cs
index b636f81..c9eec3f 100644
--- a/HDL_ON/UI/UI2/FuntionControlView/VideoDoorLock/VideoDoorLockPage.cs
+++ b/HDL_ON/UI/UI2/FuntionControlView/VideoDoorLock/VideoDoorLockPage.cs
@@ -363,6 +363,8 @@
});
}
+
+
/// <summary>
/// 閲嶆柊璁$畻瀹藉害(璁惧鍚嶇О,鎴块棿鎺т欢)
/// </summary>
@@ -383,6 +385,26 @@
this.cellFrame.X = this.btnCurrDeviceRoom.Right + Application.GetRealWidth(20);
}
+ /// <summary>
+ /// 鏇存柊鐘舵��
+ /// </summary>
+ public void UpdateState(PushMessageType pushMessageType)
+ {
+ CommonMethod.Current.MainThread(() =>
+ {
+ if (this.btnDoorLockIcon != null && !this.btnDoorLockIcon.IsSelected)
+ {
+ this.btnDoorLockIcon.IsSelected = false;
+ }
+ //闂ㄩ攣鐢垫睜鍊�
+ if (this.btnCell != null)
+ {
+ //videoDoorLockPage.btnCell.Text = "";
+ }
+ });
+
+ }
+
}
/// <summary>
/// 鑷繁寮勪竴涓狥rameLayout
--
Gitblit v1.8.0