From 80c3a496b39dd0acf87714ab50cd0dad43856550 Mon Sep 17 00:00:00 2001 From: wangzhaoyao Date: Wed, 11 Jan 2023 16:31:12 +0800 Subject: [PATCH] 1.update --- ios/Classes/Api/MOPAppletDelegate.m | 4 ++-- lib/api.dart | 2 +- lib/mop.dart | 1 - 3 files changed, 3 insertions(+), 4 deletions(-) diff --git a/ios/Classes/Api/MOPAppletDelegate.m b/ios/Classes/Api/MOPAppletDelegate.m index eb8372f..9dab0d9 100644 --- a/ios/Classes/Api/MOPAppletDelegate.m +++ b/ios/Classes/Api/MOPAppletDelegate.m @@ -95,14 +95,14 @@ NSError *parseError = nil; NSMutableDictionary *shareDic = [[NSMutableDictionary alloc] initWithDictionary:[self dictionaryRepresentation:appletInfo]]; [shareDic setValue:@{@"desc" : shareDic[@"originalInfo"][@"customData"][@"detailDescription"]} forKey:@"params"]; + [shareDic setValue:contentInfo[@"query"] forKey:@"query"]; NSData *jsonData = [NSJSONSerialization dataWithJSONObject:shareDic options:NSJSONWritingPrettyPrinted error:&parseError]; NSString *jsonString = [[NSString alloc] initWithData:jsonData encoding:NSUTF8StringEncoding]; NSDictionary *arguments = @{ @"appId": contentInfo[@"appId"], @"path": contentInfo[@"path"], @"menuId": contentInfo[@"menuId"], - @"appInfo": jsonString, - @"query" : contentInfo[@"query"] + @"appInfo": jsonString }; FlutterMethodChannel *channel = [[MopPlugin instance] methodChannel]; [channel invokeMethod:@"extensionApi:onCustomMenuClick" arguments:arguments result:^(id _Nullable result) { diff --git a/lib/api.dart b/lib/api.dart index 1b36487..db43d4b 100644 --- a/lib/api.dart +++ b/lib/api.dart @@ -33,7 +33,7 @@ abstract class AppletHandler { ///自定义菜单点击处理 Future onCustomMenuClick( - String appId, String path, String menuId, String appInfo, String query); + String appId, String path, String menuId, String appInfo); ///打开小程序 Future appletDidOpen(String appId); diff --git a/lib/mop.dart b/lib/mop.dart index a275ded..e70d79e 100644 --- a/lib/mop.dart +++ b/lib/mop.dart @@ -608,7 +608,6 @@ class Mop { params["path"], params["menuId"], params["appInfo"], - params["query"], ); }; _appletHandlerApis["appletDidOpen"] = (params) async {