打开小程序的接口支持传服务器信息
parent
d92790ddb2
commit
7ccda74c43
16
lib/mop.dart
16
lib/mop.dart
|
@ -94,14 +94,26 @@ class Mop {
|
||||||
/// [query] is miniprogram query parameters. example key1=value1&key2=value2
|
/// [query] is miniprogram query parameters. example key1=value1&key2=value2
|
||||||
///
|
///
|
||||||
///
|
///
|
||||||
Future<Map> openApplet(final String appId,
|
Future<Map> openApplet(
|
||||||
{final String path, final String query, final int sequence}) async {
|
final String appId, {
|
||||||
|
final String path,
|
||||||
|
final String query,
|
||||||
|
final int sequence,
|
||||||
|
final String apiServer,
|
||||||
|
final String apiPrefix,
|
||||||
|
final String fingerprint,
|
||||||
|
final String cryptType,
|
||||||
|
}) async {
|
||||||
Map<String, Object> params = {'appId': appId};
|
Map<String, Object> params = {'appId': appId};
|
||||||
Map param = {};
|
Map param = {};
|
||||||
if (path != null) param["path"] = path;
|
if (path != null) param["path"] = path;
|
||||||
if (query != null) param["query"] = query;
|
if (query != null) param["query"] = query;
|
||||||
if (param.length > 0) params["params"] = param;
|
if (param.length > 0) params["params"] = param;
|
||||||
if (sequence != null) params["sequence"] = sequence;
|
if (sequence != null) params["sequence"] = sequence;
|
||||||
|
if (apiServer != null) params["apiServer"] = apiServer;
|
||||||
|
if (apiPrefix != null) params["apiPrefix"] = apiPrefix;
|
||||||
|
if (fingerprint != null) params["fingerprint"] = fingerprint;
|
||||||
|
if (cryptType != null) params["cryptType"] = cryptType;
|
||||||
final Map ret = await _channel.invokeMethod('openApplet', params);
|
final Map ret = await _channel.invokeMethod('openApplet', params);
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue