I have table View with grouped style with three sections.
Get information from dictionary array.
My apps works good with UITable (Master) and one UIView (root). but, I would like to Continue pushing the information from that Cell which selected to a third UIView which is connected directly to UIView (root).
-UIView (root) have:
.h
@property (strong, nonatomic) id detailItem;
.m
#import "DetailViewController.h"
@interface DetailViewController ()
- (void)configureView;
@end
@implementation DetailViewController
@synthesize detailItem = _detailItem;
@synthesize courseDetailLabel = _courseDetailLabel;
#pragma mark - Managing the detail item
- (void)setDetailItem:(id)newDetailItem
{
if (_detailItem != newDetailItem) {
_detailItem = newDetailItem;
// Update the view.
[self configureView];
}
}
- (void)configureView
{
// Update the user interface for the detail item.
if (self.detailItem) {
self.courseDetailLabel.text = [[self.detailItem valueForKey:@"courseDetails"] description];
}
}
You should rethink your design – If the data needed to populate your views/tables/cells/etc is needed across many screens throughout your application, you should create a singleton class that manages this data and is accessible from any view controllers that needs it. This way, all you need to “push” between your views are indexes that will point the controllers to the data they need.