Notification监听cell
作者:
frola_ | 来源:发表于
2017-11-06 11:51 被阅读0次- (void)notificationdo: (NSNotification *) sender{
if ([sender.object isKindOfClass:[UITextView class]]) {
UITextView * textView = (UITextView *) sender.object;
if (self.type == StateTypeException) {
//遍历所有的cell,返回所有可见行的路径
NSArray * array = self.tableView.indexPathsForVisibleRows;
for (NSIndexPath * path in array) {
JMEAttendanceNewStyleCell *cell = [self.tableView cellForRowAtIndexPath:path];//
if (sender.object == cell.textView1) {
//输入key=indexpath.row
if (self.type == StateTypeException) {
[_beizhuDetail setValue:textView.text forKey:[NSString stringWithFormat:@"@%ld",path.row]];
}
}
}
}else{
if (![self.inputString isEqualToString:self.otherInfo]) {
self.showWarning = YES;
}
NSLog(@"------%@",self.inputString);
}
}
}
本文标题:Notification监听cell
本文链接:https://www.haomeiwen.com/subject/eotlmxtx.html
网友评论