iOS第三方支付-支付宝支付

处理手机中有无支付宝的情况支付宝调用接口:

- (void)payOrder:(NSString *)orderStr
      fromScheme:(NSString *)schemeStr
        callback:(CompletionBlock)completionBlock;

需要在调这个借口前面加上

 UIWindow *window = [[[UIApplication sharedApplication]windows]objectAtIndex:0];
                    if (window.hidden) {
                         window.hidden = NO;
                    }

需要在接口回调里面加上

UIWindow *window = [[[UIApplication sharedApplication]windows]objectAtIndex:0];
                            window.hidden = YES;

有支付宝会跳转到支付宝页面,无支付宝会弹出支付宝网页

posted @ 2015-08-13 14:23  幻想无极  阅读(313)  评论(0编辑  收藏  举报