This commit is contained in:
启星
2026-01-14 20:36:58 +08:00
parent 705d891c51
commit 5548f5d6a5
64 changed files with 482 additions and 103 deletions

View File

@@ -11,6 +11,7 @@ NS_ASSUME_NONNULL_BEGIN
@interface QXChatViewController : QXBaseViewController
@property (nonatomic,strong)TUIChatConversationModel *data;
@property (nonatomic,assign)BOOL isServices;
@end
NS_ASSUME_NONNULL_END

View File

@@ -118,6 +118,7 @@
}else{
TUIC2CChatViewController *vc = [[TUIC2CChatViewController alloc] init];
vc.isServices = self.isServices;
[vc setConversationData:self.data];
// TUIC2CChatViewController ViewController
vc.view.frame = CGRectMake(0, NavContentHeight, SCREEN_WIDTH, SCREEN_HEIGHT-NavContentHeight);

View File

@@ -13,11 +13,14 @@
#import "QXSystemTopView.h"
#import "QXSystemNoticeViewController.h"
#import "QXMessageServices.h"
#import "AppDelegate.h"
@interface QXMessageViewController ()<TUIConversationListControllerListener,QXSystemTopViewDelegate>
@property (nonatomic,strong)QXSystemTopView *topView;
@property (nonatomic,strong)QXMessageModel *model;
@property (nonatomic,strong)TUIConversationListController *vc;
@property (nonatomic,strong)NSString *service_user_id;
@property (nonatomic,strong)NSString *service_user_name;
@end
@implementation QXMessageViewController
@@ -102,6 +105,11 @@
data.groupID = conversation.groupID;
data.title = conversation.title;
data.faceUrl = conversation.faceUrl;
if ([conversation.userID isEqualToString:[NSString stringWithFormat:@"u%@",self.service_user_id]]) {
vc.isServices = YES;
}else{
vc.isServices = NO;
}
vc.data = data;
[self.vc.dataProvider markConversationAsRead:conversation];
[self.navigationController pushViewController:vc animated:YES];
@@ -117,6 +125,15 @@
[QXMessageServices getHomeMessageSuccessBlock:^(QXMessageModel * _Nonnull model) {
weakSelf.model = model;
weakSelf.topView.model = model;
AppDelegate *delegate = (AppDelegate *)[UIApplication sharedApplication].delegate;
delegate.tabbarVC.systemUnreadNumber = model.system_no_read_count.integerValue + model.announcement_read_count.integerValue;
} failBlock:^(NSError * _Nonnull error, NSString * _Nonnull msg) {
}];
[QXMessageServices getSerbviceUserSuccessBlock:^(NSString * _Nonnull user_id, NSString * _Nonnull user_name) {
weakSelf.service_user_id = user_id;
weakSelf.service_user_name = user_name;
} failBlock:^(NSError * _Nonnull error, NSString * _Nonnull msg) {
}];
@@ -137,7 +154,7 @@
-(QXSystemTopView *)topView{
if (!_topView) {
_topView = [[QXSystemTopView alloc] initWithFrame:CGRectMake(0, 0, SCREEN_WIDTH, 74+8)];
_topView = [[QXSystemTopView alloc] initWithFrame:CGRectMake(0, 0, SCREEN_WIDTH, 74*2+8)];
_topView.delegate = self;
}
return _topView;