나는 단지 기본값 인 셀을 표시하는 UITableViewController가 있습니다. 각 셀을 터치하고 첫 번째보기의 각 셀에있는 "계정"내에있는 목록으로 이동할 수 있습니다. prepareForSegue 및 속성 설정 설정
은 내가 SEGUE와 함께 모든 것을 연결 한 후 처음으로보기에 나는 전화 :- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
if ([segue.identifier isEqualToString:@"showDetail"]) {
NSIndexPath *indexPath = [self.tableView indexPathForSelectedRow];
Account *nextAccount = [self.list objectAtIndex:indexPath.row];
DetailViewController *viewController = (DetailViewController *)[segue destinationViewController];
viewController.account = nextAccount;
}
}
하고 상세 뷰의 viewDidAppear에 : 내가 말 (BOOL)이 애니메이션 :
- (void)viewDidAppear:(BOOL)animated {
self.list = [self.account.list mutableCopy];
}
및 다음 세부 뷰에있는 UITableViewController 있지만 cellForRowAtIndexPath : 메서드를 self.list 액세스 할 수 있지만 작동하지 않는 것. 나는 내 cellForRowAtIndexPath를 알고있다. 이전에이 메소드로 템플릿 작업을했기 때문에 제대로 작동했다. prepareForSegue : 작동하지 않거나 속성을 설정하지 않은 것 같습니다.
미리 감사드립니다.
나 시도 가게를 – muscletech