美文网首页
一个小坑,tap收走tablevew的didSelect

一个小坑,tap收走tablevew的didSelect

作者: 碧玉小瑕 | 来源:发表于2016-10-27 19:18 被阅读13次

UITapGestureRecognizer*tap = [[UITapGestureRecognizeralloc]initWithTarget:selfaction:@selector(tapAction)];

tap.numberOfTapsRequired=1;

tap.numberOfTouchesRequired=1;

[self.tableView addGestureRecognizer:tap];

-(void)tapAction

{

[self.tableView endEditing:yes];

}

}

-(void)tableView:(UITableView*)tableView didSelectRowAtIndexPath:(NSIndexPath*)indexPath

{

DebugLog(@"did select");

//OrderModel *model = self.modelArr[indexPath.section];

ComIndentModel*model =self.comIndentModelArray[indexPath.section];

if([model.invalidFlagisEqualToString:@"C1"] || [model.invalidFlagisEqualToString:@"C2"] || [model.invalidFlagisEqualToString:@"C3"]) {

return;

}

DetailViewController*vc = [[DetailViewControlleralloc]init];

vc.appNo= model.appNo;

[self.navigationControllerpushViewController:vcanimated:YES];

}

两者冲突,致使didSelect不起作用

相关文章

网友评论

      本文标题:一个小坑,tap收走tablevew的didSelect

      本文链接:https://www.haomeiwen.com/subject/qadsuttx.html