提交 c7a0a0af authored 作者: JarvanMo's avatar JarvanMo

update #467

上级 95118897
...@@ -79,6 +79,8 @@ FlutterMethodChannel *channel = nil; ...@@ -79,6 +79,8 @@ FlutterMethodChannel *channel = nil;
[self handleSubscribeWithCall:call result:result]; [self handleSubscribeWithCall:call result:result];
} else if ([@"autoDeduct" isEqualToString:call.method]) { } else if ([@"autoDeduct" isEqualToString:call.method]) {
[self handleAutoDeductWithCall:call result:result]; [self handleAutoDeductWithCall:call result:result];
} else if ([@"autoDeductV2" isEqualToString:call.method]) {
[self handleautoDeductV2:call result:result];
} else if ([@"openBusinessView" isEqualToString:call.method]) { } else if ([@"openBusinessView" isEqualToString:call.method]) {
[self handleOpenBusinessView:call result:result]; [self handleOpenBusinessView:call result:result];
}else if([@"authByPhoneLogin" isEqualToString:call.method]){ }else if([@"authByPhoneLogin" isEqualToString:call.method]){
...@@ -221,7 +223,6 @@ FlutterMethodChannel *channel = nil; ...@@ -221,7 +223,6 @@ FlutterMethodChannel *channel = nil;
}]; }];
} }
- (void)handleAutoDeductWithCall:(FlutterMethodCall *)call result:(FlutterResult)result { - (void)handleAutoDeductWithCall:(FlutterMethodCall *)call result:(FlutterResult)result {
NSMutableDictionary *paramsFromDart = [NSMutableDictionary dictionaryWithDictionary:call.arguments]; NSMutableDictionary *paramsFromDart = [NSMutableDictionary dictionaryWithDictionary:call.arguments];
[paramsFromDart removeObjectForKey:@"businessType"]; [paramsFromDart removeObjectForKey:@"businessType"];
...@@ -234,6 +235,17 @@ FlutterMethodChannel *channel = nil; ...@@ -234,6 +235,17 @@ FlutterMethodChannel *channel = nil;
}]; }];
} }
- (void)handleautoDeductV2:(FlutterMethodCall *)call result:(FlutterResult)result {
NSMutableDictionary *paramsFromDart = call.arguments[@"queryInfo"];
// [paramsFromDart removeObjectForKey:@"businessType"];
WXOpenBusinessWebViewReq *req = [[WXOpenBusinessWebViewReq alloc] init];
NSNumber *businessType = call.arguments[@"businessType"];
req.businessType = [businessType unsignedIntValue];
req.queryInfoDic = paramsFromDart;
[WXApi sendReq:req completion:^(BOOL done) {
result(@(done));
}];
}
- (void)handleOpenBusinessView:(FlutterMethodCall *)call result:(FlutterResult)result { - (void)handleOpenBusinessView:(FlutterMethodCall *)call result:(FlutterResult)result {
NSDictionary *params = call.arguments; NSDictionary *params = call.arguments;
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论