diff --git a/android/src/main/java/com/finogeeks/mop/api/mop/BaseModule.java b/android/src/main/java/com/finogeeks/mop/api/mop/BaseModule.java index 7f5d87b..627a43d 100644 --- a/android/src/main/java/com/finogeeks/mop/api/mop/BaseModule.java +++ b/android/src/main/java/com/finogeeks/mop/api/mop/BaseModule.java @@ -76,6 +76,10 @@ public class BaseModule extends BaseApi { if (debug == null) debug = false; Boolean bindAppletWithMainProcess = (Boolean) param.get("bindAppletWithMainProcess"); if (bindAppletWithMainProcess == null) bindAppletWithMainProcess = false; + Integer pageCountLimit = (Integer) param.get("pageCountLimit"); + if (pageCountLimit == null) { + pageCountLimit = 0; + } String customWebViewUserAgent = (String) param.get("customWebViewUserAgent"); Integer appletIntervalUpdateLimit = (Integer) param.get("appletIntervalUpdateLimit"); @@ -117,7 +121,8 @@ public class BaseModule extends BaseApi { .setUserId(userId) .setDebugMode(debug) .setDisableRequestPermissions(disablePermission) - .setBindAppletWithMainProcess(bindAppletWithMainProcess); + .setBindAppletWithMainProcess(bindAppletWithMainProcess) + .setPageCountLimit(pageCountLimit); if (customWebViewUserAgent != null) builder.setCustomWebViewUserAgent(customWebViewUserAgent); diff --git a/ios/Classes/Api/MOPAppletDelegate.m b/ios/Classes/Api/MOPAppletDelegate.m index 01236af..7ef44c8 100644 --- a/ios/Classes/Api/MOPAppletDelegate.m +++ b/ios/Classes/Api/MOPAppletDelegate.m @@ -134,14 +134,14 @@ static NSString *scheme = @"fatae55433be2f62915";//App对应的scheme } - (void)getPhoneNumberWithAppletInfo:(FATAppletInfo *)appletInfo bindGetPhoneNumber:(void (^)(NSDictionary *))bindGetPhoneNumber { - self.bindGetPhoneNumber = bindGetPhoneNumber; - FlutterMethodChannel *channel = [[MopPlugin instance] methodChannel]; - [channel invokeMethod:@"extensionApi:getPhoneNumber" arguments:@{} result:^(id _Nullable result) { + NSDictionary *params = @{@"name":@"getPhoneNumber"}; + FlutterMethodChannel *channel = [[MopPlugin instance] methodChannel]; + [channel invokeMethod:@"extensionApi:getPhoneNumber" arguments:params result:^(id _Nullable result) { + !bindGetPhoneNumber?: bindGetPhoneNumber(result); }]; } - @end @implementation NSString (FATEncode) diff --git a/ios/Classes/Api/MOP_currentApplet.m b/ios/Classes/Api/MOP_currentApplet.m index 75e0ccc..d4f4f41 100644 --- a/ios/Classes/Api/MOP_currentApplet.m +++ b/ios/Classes/Api/MOP_currentApplet.m @@ -33,4 +33,8 @@ } } ++ (void)load { + +} + @end diff --git a/ios/mop.podspec b/ios/mop.podspec index 94cf3e3..9e7afd7 100644 --- a/ios/mop.podspec +++ b/ios/mop.podspec @@ -17,7 +17,7 @@ A finclip miniprogram flutter sdk. s.dependency 'Flutter' s.ios.deployment_target = '9.0' - s.dependency 'FinApplet' , '2.37.0-alpha20220428v07' - s.dependency 'FinAppletExt' , '2.37.0-alpha20220428v07' + s.dependency 'FinApplet' , '2.37.0-alpha20220512v03' + s.dependency 'FinAppletExt' , '2.37.0-alpha20220512v03' end diff --git a/lib/mop.dart b/lib/mop.dart index d27eaf2..9490270 100644 --- a/lib/mop.dart +++ b/lib/mop.dart @@ -315,6 +315,7 @@ class Mop { String? userId, bool debug = false, bool bindAppletWithMainProcess = false, + int? pageCountLimit = 0, List? finStoreConfigs, UIConfig? uiConfig, String? customWebViewUserAgent, @@ -335,6 +336,7 @@ class Mop { 'userId': userId, "debug": debug, "bindAppletWithMainProcess": bindAppletWithMainProcess, + "pageCountLimit": pageCountLimit, "finStoreConfigs": storeConfigs, "uiConfig": uiConfig?.toMap(), "customWebViewUserAgent": customWebViewUserAgent,