// // FKCirAllCommentViewModel.m // FirstLink // // Created by jack on 16/6/16. // Copyright © 2016年 FirstLink. All rights reserved. // #import "FKCirAllCommentViewModel.h" @implementation FKCirAllCommentViewModel - (NSString *)getCommentPlaceHolderWithRow:(NSInteger)row{ // if (self.defaultCommentItem) { // return [NSString stringWithFormat:@"回复 %@", self.defaultCommentItem.buyerNickName]; // } FKCircleCommentItem *item = [self commentItemAtIndex:row]; if (![item isSelfComment]){ return [NSString stringWithFormat:@"回复 %@", item.nickName]; } return @""; } - (void)appendMoreContent:(NSArray *)moreArray{ if (moreArray.count <= 0) return; self.dataArray = [self.dataArray arrayByAddingObjectsFromArray:moreArray]; } - (FKCircleCommentItem *)commentItemAtIndex:(NSInteger)index{ if (index >= 0 && index < self.dataArray.count) { return self.dataArray[index]; } return nil; } @end