Commit 4cd8c01f authored by Steven杜宇's avatar Steven杜宇

// 消息红点增加UAT逻辑

parent c2d94078
......@@ -251,7 +251,12 @@ extension YHHomeHoldViewPageViewController {
[weak self] success, error in
guard let self = self else { return }
DispatchQueue.main.async {
self.msgUnreadView.unreadCount = self.msgViewModel.unreadTotalCount + YHButlerServiceManager.shared.unreadCount
var unreadCount = self.msgViewModel.unreadTotalCount
if YHButlerServiceManager.shared.isUatAllowed() {
unreadCount = self.msgViewModel.unreadTotalCount + YHButlerServiceManager.shared.unreadCount
}
self.msgUnreadView.unreadCount = unreadCount
}
}
}
......
......@@ -103,10 +103,13 @@ class YHMessageListVC: YHBaseViewController {
view.addSubview(tableView)
// 银河管家 始终放在第一位
let mgrMsg = YHMessageInfoModel()
mgrMsg.type = YHMessageType.yinheManager.rawValue
mgrMsg.unreadCount = YHButlerServiceManager.shared.unreadCount
msgArr.append(mgrMsg)
if YHButlerServiceManager.shared.isUatAllowed() {
let mgrMsg = YHMessageInfoModel()
mgrMsg.type = YHMessageType.yinheManager.rawValue
mgrMsg.unreadCount = YHButlerServiceManager.shared.unreadCount
msgArr.append(mgrMsg)
}
self.tableView.reloadData()
navBar.snp.makeConstraints { make in
......@@ -339,6 +342,10 @@ extension YHMessageListVC {
}
@objc func didRefreshYinHeManagerUnreadMsg() {
if !YHButlerServiceManager.shared.isUatAllowed() {
return
}
for msg in msgArr {
if msg.type == YHMessageType.yinheManager.rawValue { // 银河管家
msg.unreadCount = YHButlerServiceManager.shared.unreadCount
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment