whose view is not in the window hierarchy!
它的视图不在窗口层次结构中
warning:Attempt to present <UIAlertController:0x79..>on
<PadRootTabBarControllerViewController:0x7f..> whose view is not in the window hierarchy!
因为这个viewController是模态出来的即他不在原来的TabBar的上面即没有入栈,所以会出现上面的现象.
解决办法:要在当前的viewController上面呈现UIAlertController而不是在隐藏的那个根视图UITabBarViewController上面呈现
如果不是模态出来的而是Push出来的因为Push出来的viewController入栈了,所以运行正常