跳转回制定控制器

来源:互联网 发布:手机淘宝退货流程图 编辑:程序博客网 时间:2024/06/01 10:18

不多说,直接上代码

#pragma mark  --  网络请求//验证支付密码- (void)setPayPassword {    NSString *url = [NSString stringWithFormat:@"/sdyc/app/pay/password/valid/v1"];    NSMutableDictionary *dict = [NSMutableDictionary dictionary];    dict[@"payPassword"] = [RSA encryptString:_passwordTextField.text publicKey:[LTools cacheForKey:user_publicKey]];    dict[@"userId"] = [LTools cacheForKey:User_id];    [[YJYRequstManager shareInstance] requestWithMethod:YJYRequstMethodPost api:url parameters:dict constructingBodyBlock:nil completion:^(NSDictionary *result) {        NSDictionary *Dic = [result objectForKey:@"meta"];        if ([[Dic objectForKey:@"success"] integerValue] == 1)        {            [MBProgressHUD hideHUDForView:self.view animated:YES];            [LTools cache:@"1" ForKey:User_isPayPassword];            //跳转回指定控制器            for (UIViewController *vc in self.navigationController.viewControllers) {                if ([vc isKindOfClass:[MLMineDetailController class]]) {                    [self.navigationController popToViewController:vc animated:YES];                }            }        }    } failBlock:^(NSDictionary *result) {        NSLog(@"%@",result);    }];}
原创粉丝点击