IVTHotAndFollowVideoModel.m
1.03 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
//
// IVTHotAndFollowVideoModel.m
// IVTMeLiveTwo
//
// Created by xrg on 16/8/25.
// Copyright © 2016年 QLQ. All rights reserved.
//
#import "IVTHotAndFollowVideoModel.h"
@implementation IVTHotAndFollowVideoModel
- (id)initWithDict:(NSDictionary *)liveDict
{
if (self = [super init]) {
self.userIDToLive = liveDict[@"userId"];
self.userid = [NSString stringWithFormat:@"%ld",[liveDict[@"id"] integerValue]];
self.liveRoomName = liveDict[@"name"];
self.name = liveDict[@"nick"];
self.city = liveDict[@"location"];
self.url = liveDict[@"videoAddr"];
self.portrait = liveDict[@"avatar"];
self.thumbnail = liveDict[@"thumbnail"];
self.online_users = [liveDict[@"audienceNowNum"] intValue];
self.chatRoomJid = liveDict[@"chatroomAddr"];
self.miTangNumber = [liveDict[@"mecoinbalance"] intValue];
}
return self;
}
- (void)setValue:(id)value forUndefinedKey:(NSString *)key
{
if ([key isEqualToString:@"id"]) {
self.ID = value;
}
}
@end