1
0
Code Issues Pull Requests Packages Projects Releases Wiki Activity GitHub Gitee

feat: 添加获取当前 SDK 版本 API。

This commit is contained in:
jaywcjlove
2020-07-14 15:39:41 +08:00
parent fb9a44575d
commit c16c1be2c0
6 changed files with 67 additions and 9 deletions

View File

@@ -71,6 +71,12 @@ public class AlipayModule extends ReactContextBaseJavaModule {
payThread.start();
}
@ReactMethod
public void getVersion(Promise promise) {
PayTask payTask = new PayTask(getCurrentActivity());
promise.resolve(payTask.getVersion());
}
private WritableMap getWritableMap(Map<String, String> map) {
WritableMap writableMap = Arguments.createMap();
for (Map.Entry<String, String> entry : map.entrySet()) {