|
|
@@ -132,6 +132,8 @@
|
|
|
@property (nonatomic,weak) UITapGestureRecognizer *tap;
|
|
|
@property (nonatomic,assign) BOOL showKeyboard;
|
|
|
|
|
|
+@property (nonatomic,strong) NSIndexPath *containerSelectedIndexPath;
|
|
|
+
|
|
|
@end
|
|
|
|
|
|
@implementation DetailPageViewController
|
|
|
@@ -376,6 +378,19 @@
|
|
|
|
|
|
}];
|
|
|
}
|
|
|
+ // 设置默认选中第一个Container
|
|
|
+ for (NSInteger i = 0; i < self.content.segments.count; i++) {
|
|
|
+
|
|
|
+ NSMutableDictionary* segment = [self.content.segments[i] mutableCopy];
|
|
|
+ NSString* type =[segment valueForKey:@"_type"];
|
|
|
+
|
|
|
+ if([type isEqualToString:@"tracking"]) {
|
|
|
+ NSIndexPath *indexPath = [NSIndexPath indexPathForRow:0 inSection:i];
|
|
|
+ [self.table selectRowAtIndexPath:indexPath animated:NO scrollPosition:UITableViewScrollPositionNone];
|
|
|
+ [self tableView:self.table didSelectRowAtIndexPath:indexPath];
|
|
|
+ break;
|
|
|
+ }
|
|
|
+ }
|
|
|
|
|
|
// [self.table setNeedsDisplay];
|
|
|
// if(self.recordCount<2000)
|
|
|
@@ -1369,6 +1384,7 @@
|
|
|
if([type isEqualToString:@"tracking"]) {
|
|
|
NSDictionary *location = [segment objectForKey:@"location"];
|
|
|
[self.shipMap showShipAnnotaion:location];
|
|
|
+ self.containerSelectedIndexPath = indexPath;
|
|
|
}
|
|
|
|
|
|
|