A push to B, B中有个alertView 点击ok希

2019-07-10  本文已影响0人  _哈哈哈哈哈哈

B中创建alertView的时候传入参数:B控制器。 

然后

UIAlertController *alertController = [UIAlertController alertControllerWithTitle:nil message:@"Subscribed!" preferredStyle:UIAlertControllerStyleAlert];

    UIAlertAction *okAction = [UIAlertAction actionWithTitle:@"OK" style:UIAlertActionStyleCancel handler:^(UIAlertAction * _Nonnull action) {

        [self.vc.navigationController popViewControllerAnimated:YES];

    }];

    [alertControlleraddAction:okAction];

上一篇 下一篇

猜你喜欢

热点阅读