Commit 8fd31c33 by lee

u deeplink open view animated

parent ff59cbe9
......@@ -21,6 +21,10 @@
return [[AppDelegate mainViewController] selectedViewController];
}
- (void) pushViewController:(UIViewController *) vc {
[[self navigationController] pushViewController:vc animated:[[UIApplication sharedApplication] applicationState] == UIApplicationStateActive];
}
- (void)registerRouter {
JLRoutes *routes = [JLRoutes routesForScheme:@"cemarose"];
[routes addRoute:@"/collections/:handle/*" handler:^BOOL(NSDictionary<NSString *,id> * _Nonnull parameters) {
......@@ -35,13 +39,14 @@
brandCaramelVC.isSale = NO;
brandCaramelVC.handle = handle;
brandCaramelVC.brand = handle;
[[self navigationController] pushViewController:brandCaramelVC animated:NO];
[self pushViewController:brandCaramelVC];
}else{
KWMSelectedGoodsVC * selectedGoodsVC = (KWMSelectedGoodsVC *)[KWMBaseVC findControllerBy:[KWMSelectedGoodsVC kwmTag] fromStoryboard:@"New"];
selectedGoodsVC.handle = handle;
selectedGoodsVC.ctags = tags;
selectedGoodsVC.title = parameters[@"title"];
[[AppDelegate mainViewController].selectedViewController pushViewController:selectedGoodsVC animated:NO];
[self pushViewController:selectedGoodsVC];
}
return YES;
}];
......@@ -52,7 +57,7 @@
// productDetailVC.product = brandCell.leftProduct;
vc.handle = parameters[@"id"];
// NSLog(@"%@",[AppDelegate mainViewController].selectedViewController);
[[AppDelegate mainViewController].selectedViewController pushViewController:vc animated:NO];
[self pushViewController:vc];
return YES;
}];
[routes addRoute:@"/blogs/:blog/:handle" handler:^BOOL(NSDictionary<NSString *,id> * _Nonnull parameters) {
......@@ -60,7 +65,7 @@
blogDetailVC.handle = parameters[@"handle"];
blogDetailVC.type = KWMContentTypeBlog;;
blogDetailVC.title = parameters[@"title"];
[[AppDelegate mainViewController].selectedViewController pushViewController:blogDetailVC animated:NO];
[self pushViewController:blogDetailVC];
return YES;
}];
[routes addRoute:@"/pages/:handle" handler:^BOOL(NSDictionary<NSString *,id> * _Nonnull parameters) {
......@@ -68,7 +73,7 @@
blogDetailVC.handle = parameters[@"handle"];
blogDetailVC.type = KWMContentTypePage;
blogDetailVC.title = parameters[@"title"];
[[AppDelegate mainViewController].selectedViewController pushViewController:blogDetailVC animated:NO];
[self pushViewController:blogDetailVC];
return YES;
}];
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment