UIAlertAction *cancelAction = [UIAlertAction actionWithTitle:@"拍照" style:UIAlertActionStyleDestructive handler:^(UIAlertAction * _Nonnull action) {
NSLog(@"拍照");
}];
UIAlertAction *sureAction = [UIAlertAction actionWithTitle:@"相册" style:UIAlertActionStyleDestructive handler:^(UIAlertAction * _Nonnull action) {
NSLog(@"相册");
}];
UIAlertController *alertVC = [UIAlertController alertControllerWithTitle:@"提示" message:@"请选择调用方式" preferredStyle:UIAlertControllerStyleAlert];
[alertVC addAction:cancelAction];
[alertVC addAction:sureAction];
[self presentViewController:alertVC animated:YES completion:^{
}];