|
@@ -35,7 +35,7 @@
|
|
|
|
|
|
- (void)confignRecomFriendCell:(SLRecomFriendModel *)model {
|
|
|
self.recomFriendModel = model;
|
|
|
- [self.headImageView sd_setImageWithURL:[NSURL URLWithString:[model getUserHeadUrl]]];
|
|
|
+ [self.headImageView sd_setImageWithURL:[NSURL URLWithString:[model getUserHeadUrl]] placeholderImage:ImageName(@"icon_ellipse")];
|
|
|
self.nameLabel.text = model.userName;
|
|
|
self.friendNumLabel.text = model.mutualFriends;
|
|
|
if (model.addSuccess) {
|
|
@@ -60,7 +60,7 @@
|
|
|
[obj removeFromSuperview];
|
|
|
obj = nil;
|
|
|
}];
|
|
|
- NSArray *interests = [model.interests componentsSeparatedByString:@","];
|
|
|
+ NSArray *interests = model.interests.length ? [model.interests componentsSeparatedByString:@","] : @[];
|
|
|
__block CGFloat x = 0;
|
|
|
[interests enumerateObjectsUsingBlock:^(NSString *obj, NSUInteger idx, BOOL * _Nonnull stop) {
|
|
|
CGRect rect = YMBoundWidth(obj, [UIFont systemFontOfSize:12]);
|
|
@@ -78,6 +78,7 @@
|
|
|
x += width + 28;
|
|
|
}];
|
|
|
self.interestcrollView.contentSize = CGSizeMake(x, 24);
|
|
|
+ self.interestcrollView.hidden = !interests.count;
|
|
|
}
|
|
|
|
|
|
- (UIScrollView *)interestcrollView {
|