From b1da18fdf77bed4fd49a4ab70ec636d793c6ee1b Mon Sep 17 00:00:00 2001 From: Derek316x Date: Sun, 21 Feb 2016 16:01:24 -0500 Subject: [PATCH] fixed --- FixaDaApp/FixaDaApp.xcodeproj/project.pbxproj | 2 ++ .../FixaDaApp/Base.lproj/Main.storyboard | 22 ++++++++++++++----- FixaDaApp/FixaDaApp/FoursquareAPIManager.m | 1 + FixaDaApp/FixaDaApp/ViewController.m | 3 ++- 4 files changed, 22 insertions(+), 6 deletions(-) diff --git a/FixaDaApp/FixaDaApp.xcodeproj/project.pbxproj b/FixaDaApp/FixaDaApp.xcodeproj/project.pbxproj index d7126a8..de293cd 100644 --- a/FixaDaApp/FixaDaApp.xcodeproj/project.pbxproj +++ b/FixaDaApp/FixaDaApp.xcodeproj/project.pbxproj @@ -352,6 +352,7 @@ buildSettings = { ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; INFOPLIST_FILE = FixaDaApp/Info.plist; + IPHONEOS_DEPLOYMENT_TARGET = 8.4; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; PRODUCT_BUNDLE_IDENTIFIER = com.mikekavouras.FixaDaApp; PRODUCT_NAME = "$(TARGET_NAME)"; @@ -364,6 +365,7 @@ buildSettings = { ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; INFOPLIST_FILE = FixaDaApp/Info.plist; + IPHONEOS_DEPLOYMENT_TARGET = 8.4; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; PRODUCT_BUNDLE_IDENTIFIER = com.mikekavouras.FixaDaApp; PRODUCT_NAME = "$(TARGET_NAME)"; diff --git a/FixaDaApp/FixaDaApp/Base.lproj/Main.storyboard b/FixaDaApp/FixaDaApp/Base.lproj/Main.storyboard index ed571b5..b19aba0 100644 --- a/FixaDaApp/FixaDaApp/Base.lproj/Main.storyboard +++ b/FixaDaApp/FixaDaApp/Base.lproj/Main.storyboard @@ -1,8 +1,8 @@ - + - + @@ -19,13 +19,15 @@ - + + - + + - + @@ -35,16 +37,20 @@ + + + @@ -52,10 +58,16 @@ + + + + + + diff --git a/FixaDaApp/FixaDaApp/FoursquareAPIManager.m b/FixaDaApp/FixaDaApp/FoursquareAPIManager.m index b0ee3ac..ffad01c 100644 --- a/FixaDaApp/FixaDaApp/FoursquareAPIManager.m +++ b/FixaDaApp/FixaDaApp/FoursquareAPIManager.m @@ -39,6 +39,7 @@ + (void)findSomething:(NSString *)query progress:nil success:^(NSURLSessionTask *task, id responseObject) { + completion(responseObject[@"response"][@"venues"]); } failure:^(NSURLSessionTask *operation, NSError *error) { diff --git a/FixaDaApp/FixaDaApp/ViewController.m b/FixaDaApp/FixaDaApp/ViewController.m index f938005..4dcd053 100644 --- a/FixaDaApp/FixaDaApp/ViewController.m +++ b/FixaDaApp/FixaDaApp/ViewController.m @@ -39,6 +39,7 @@ - (void)viewDidLoad { self.mapView.delegate = self; self.locationManager = [[CLLocationManager alloc] init]; + [self.locationManager requestWhenInUseAuthorization]; } - (void)viewDidAppear:(BOOL)animated @@ -56,7 +57,7 @@ - (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView - (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section { - return 0; + return self.venues.count; } - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath