Skip to content

Commit 4e5fff8

Browse files
committed
update crowdloan contribution query & bump polkadot-js/api 5.6.1
1 parent 994c498 commit 4e5fff8

File tree

8 files changed

+55
-48
lines changed

8 files changed

+55
-48
lines changed

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
## [0.3.0] - 20210826
2+
3+
* bump polkadot-js/api v5.6.1
4+
* update crowdloan user's contributions query api
5+
16
## [0.2.9] - 20210803
27

38
* bump polkadot-js/api v5.5.1

example/pubspec.lock

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -269,7 +269,7 @@ packages:
269269
path: ".."
270270
relative: true
271271
source: path
272-
version: "0.2.7"
272+
version: "0.2.9"
273273
process:
274274
dependency: transitive
275275
description:

js_api/dist/main.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

js_api/package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@polkawallet/js-api",
3-
"version": "0.2.8",
3+
"version": "0.2.9",
44
"main": "index.js",
55
"license": "Apache-2.0",
66
"keywords": [
@@ -24,10 +24,10 @@
2424
"build-dev": "webpack --mode development"
2525
},
2626
"resolutions": {
27-
"@polkadot/api": "^5.5.1"
27+
"@polkadot/api": "^5.6.1"
2828
},
2929
"dependencies": {
30-
"@polkadot/api": "^5.5.1",
30+
"@polkadot/api": "^5.6.1",
3131
"@polkadot/extension-dapp": "^0.39.3",
3232
"@polkadot/ui-shared": "0.85.1",
3333
"@walletconnect/client": "2.0.0-alpha.26",

js_api/yarn.lock

Lines changed: 36 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -1946,31 +1946,31 @@
19461946
dependencies:
19471947
pino "^6.7.0"
19481948

1949-
"@polkadot/api-derive@5.5.1":
1950-
version "5.5.1"
1951-
resolved "https://registry.yarnpkg.com/@polkadot/api-derive/-/api-derive-5.5.1.tgz#6fdba748d90024f2fcdeb7827d178ff8d0ad308e"
1952-
integrity sha512-dkpl3CnroBYAlLx571KoyjI72TqRweWI61z7tzNeR8qwniNyWDEILTErUfzy5jYAO7XrZpW1Gn4WMMH+kEcqZQ==
1949+
"@polkadot/api-derive@5.6.1":
1950+
version "5.6.1"
1951+
resolved "https://registry.yarnpkg.com/@polkadot/api-derive/-/api-derive-5.6.1.tgz#4ac21dbd51bc3e862ec1d8cfdef2e482d6dfba5a"
1952+
integrity sha512-ufATfPXT3qxJ9FijAJqa+Gel/7xHoNoPv4r8fSbmvTNcayYCK5FdBEsOzb2k48ryTtRBarouqG0HIiAavXu5Gw==
19531953
dependencies:
19541954
"@babel/runtime" "^7.15.3"
1955-
"@polkadot/api" "5.5.1"
1956-
"@polkadot/rpc-core" "5.5.1"
1957-
"@polkadot/types" "5.5.1"
1955+
"@polkadot/api" "5.6.1"
1956+
"@polkadot/rpc-core" "5.6.1"
1957+
"@polkadot/types" "5.6.1"
19581958
"@polkadot/util" "^7.2.1"
19591959
"@polkadot/util-crypto" "^7.2.1"
19601960
rxjs "^7.3.0"
19611961

1962-
"@polkadot/api@5.5.1", "@polkadot/api@^5.5.1":
1963-
version "5.5.1"
1964-
resolved "https://registry.yarnpkg.com/@polkadot/api/-/api-5.5.1.tgz#0298c6d883c2264a68ae93a3b59b98263aed53d3"
1965-
integrity sha512-GS/MoRc7NB61jz7TzwX0WAA3JS7DSj3xH4ac39LcuPHXu0VMQw6LgT/5KIzYxTx+79Iwth62bKelW/Mgk23wUg==
1962+
"@polkadot/api@5.6.1", "@polkadot/api@^5.6.1":
1963+
version "5.6.1"
1964+
resolved "https://registry.yarnpkg.com/@polkadot/api/-/api-5.6.1.tgz#10ecc4fe5ccaa004501451c0acf3de5245a861d9"
1965+
integrity sha512-aL94+fwLhj65s08GqgZUPfYpWd1vrUP1jeAZryPlwF3Yzp/LpHYgnY9ZkhIsBcfHpngBV2KnveT5DNthdP2DdQ==
19661966
dependencies:
19671967
"@babel/runtime" "^7.15.3"
1968-
"@polkadot/api-derive" "5.5.1"
1968+
"@polkadot/api-derive" "5.6.1"
19691969
"@polkadot/keyring" "^7.2.1"
1970-
"@polkadot/rpc-core" "5.5.1"
1971-
"@polkadot/rpc-provider" "5.5.1"
1972-
"@polkadot/types" "5.5.1"
1973-
"@polkadot/types-known" "5.5.1"
1970+
"@polkadot/rpc-core" "5.6.1"
1971+
"@polkadot/rpc-provider" "5.6.1"
1972+
"@polkadot/types" "5.6.1"
1973+
"@polkadot/types-known" "5.6.1"
19741974
"@polkadot/util" "^7.2.1"
19751975
"@polkadot/util-crypto" "^7.2.1"
19761976
eventemitter3 "^4.0.7"
@@ -2009,45 +2009,45 @@
20092009
dependencies:
20102010
"@babel/runtime" "^7.15.3"
20112011

2012-
"@polkadot/rpc-core@5.5.1":
2013-
version "5.5.1"
2014-
resolved "https://registry.yarnpkg.com/@polkadot/rpc-core/-/rpc-core-5.5.1.tgz#4ce0646becabe7736dfb81eb902e5933158646c8"
2015-
integrity sha512-hP7a55iSpgZVqxAIpK+v63eV/nD14Tm7C1rUmfKIS6gGJFJf+sQbTmp6d7+fuKxvYfFqBrFLU8IraOhLOQ5W3Q==
2012+
"@polkadot/rpc-core@5.6.1":
2013+
version "5.6.1"
2014+
resolved "https://registry.yarnpkg.com/@polkadot/rpc-core/-/rpc-core-5.6.1.tgz#d14bf42491f2ca31bf295029804349d866d06352"
2015+
integrity sha512-gkdKj2UqNsXR2lCpZBeGndDYUSCecc+KMBUtQ6f0bofMWATv4OnbG1/JB639P91X5ue3dAj4D45oZzcEnT2fUg==
20162016
dependencies:
20172017
"@babel/runtime" "^7.15.3"
2018-
"@polkadot/rpc-provider" "5.5.1"
2019-
"@polkadot/types" "5.5.1"
2018+
"@polkadot/rpc-provider" "5.6.1"
2019+
"@polkadot/types" "5.6.1"
20202020
"@polkadot/util" "^7.2.1"
20212021
rxjs "^7.3.0"
20222022

2023-
"@polkadot/rpc-provider@5.5.1":
2024-
version "5.5.1"
2025-
resolved "https://registry.yarnpkg.com/@polkadot/rpc-provider/-/rpc-provider-5.5.1.tgz#633f4a48605623092fb9017433f2b3cd70cd96bc"
2026-
integrity sha512-wOCKeeyUa7Dw3nxKkQntnfOO471icdzqT2V7bwloBOo+G2MX8nHImO0mW3QMfJygn4qoARF1PBo1PLbDUEDgog==
2023+
"@polkadot/rpc-provider@5.6.1":
2024+
version "5.6.1"
2025+
resolved "https://registry.yarnpkg.com/@polkadot/rpc-provider/-/rpc-provider-5.6.1.tgz#b524654ce79bb57172d4bf29c3b03d853fe0a70a"
2026+
integrity sha512-YZCyERdtUMZmhXjLir5oHoZ51OPKb7G7ZP8dd780cNg6OHuxQJ8LD1Lv1iE07LXnH9yTbylFQTDOKXMg60Pb/w==
20272027
dependencies:
20282028
"@babel/runtime" "^7.15.3"
2029-
"@polkadot/types" "5.5.1"
2029+
"@polkadot/types" "5.6.1"
20302030
"@polkadot/util" "^7.2.1"
20312031
"@polkadot/util-crypto" "^7.2.1"
20322032
"@polkadot/x-fetch" "^7.2.1"
20332033
"@polkadot/x-global" "^7.2.1"
20342034
"@polkadot/x-ws" "^7.2.1"
20352035
eventemitter3 "^4.0.7"
20362036

2037-
"@polkadot/types-known@5.5.1":
2038-
version "5.5.1"
2039-
resolved "https://registry.yarnpkg.com/@polkadot/types-known/-/types-known-5.5.1.tgz#b00b0d45cbd07b4e0c3199f8ba00d10a1bd3f63d"
2040-
integrity sha512-bxBRmZ0a3lwEyWkWOKqmDJfpNKh3cp9xo6IidrQU2S5OPMjFFercB+HwJjkNE1cMtShwBYTvDheUImNkdm+FXA==
2037+
"@polkadot/types-known@5.6.1":
2038+
version "5.6.1"
2039+
resolved "https://registry.yarnpkg.com/@polkadot/types-known/-/types-known-5.6.1.tgz#aed3771dcfdfb81462455af2d727e65147446b97"
2040+
integrity sha512-7HMpsKdp3JDOiDxbG8EcMKFyJ353g5RILRPdEDxlgx5d+a1PsmyqoRXkfWe7htUXAWxblw8pUIu3ZpQ09r6AxQ==
20412041
dependencies:
20422042
"@babel/runtime" "^7.15.3"
20432043
"@polkadot/networks" "^7.2.1"
2044-
"@polkadot/types" "5.5.1"
2044+
"@polkadot/types" "5.6.1"
20452045
"@polkadot/util" "^7.2.1"
20462046

2047-
"@polkadot/types@5.5.1":
2048-
version "5.5.1"
2049-
resolved "https://registry.yarnpkg.com/@polkadot/types/-/types-5.5.1.tgz#057e8f0fc2369c0741c0f9b0224418e8f25a6938"
2050-
integrity sha512-+Cm7Y6D/98WqL8ofONyZrVvE2CxzK3/z18bATIQIWhG2w9ir9PdWaFMZ3fLCRw2Ggaq88AknguK6kXeEPcKPrA==
2047+
"@polkadot/types@5.6.1":
2048+
version "5.6.1"
2049+
resolved "https://registry.yarnpkg.com/@polkadot/types/-/types-5.6.1.tgz#008f858a90d5d4b42cd0e6d126c32c246a7c1c76"
2050+
integrity sha512-PYqhcuM67ZoQ7APgjjGr9baVfkxpeE37Kj1sjN5uOh743EbHy9tS+1IeeDbNkdeXUKDypy9MYtHPXVevzA3GaA==
20512051
dependencies:
20522052
"@babel/runtime" "^7.15.3"
20532053
"@polkadot/util" "^7.2.1"

lib/api/apiParachain.dart

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,8 @@ class ApiParachain {
1313
return AuctionData.fromJson(res);
1414
}
1515

16-
Future<String> queryUserContributions(String paraId, String pubKey) async {
17-
return service.queryUserContributions(paraId, pubKey);
16+
Future<List<String>> queryUserContributions(
17+
List<String> paraIds, String pubKey) async {
18+
return service.queryUserContributions(paraIds, pubKey);
1819
}
1920
}

lib/service/parachain.dart

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,10 @@ class ServiceParachain {
1111
return res;
1212
}
1313

14-
Future<String> queryUserContributions(String paraId, String pubKey) async {
15-
final String res = await serviceRoot.webView.evalJavascript(
16-
'parachain.queryUserContributions(api, "$paraId", "$pubKey")');
17-
return res;
14+
Future<List<String>> queryUserContributions(
15+
List<String> paraIds, String pubKey) async {
16+
final res = await serviceRoot.webView.evalJavascript('Promise.all(['
17+
'${paraIds.map((e) => 'parachain.queryUserContributions(api, "$e", "$pubKey")').join(',')}])');
18+
return List<String>.from(res);
1819
}
1920
}

pubspec.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
name: polkawallet_sdk
22
description: Flutter SDK for building plugin package for polkawallet.
3-
version: 0.2.9
3+
version: 0.3.0
44
homepage: https://polkawallet.io
55

66
environment:

0 commit comments

Comments
 (0)