Continue debug GVA cursor

This commit is contained in:
poka 2021-02-07 16:57:50 +01:00
parent 051a898904
commit e625a9bd47
2 changed files with 5 additions and 3 deletions

View File

@ -16,6 +16,7 @@ class HistoryProvider with ChangeNotifier {
List transBC;
bool isFirstBuild = true;
String fetchMoreCursor;
Map pageInfo;
Future scan() async {
await Permission.camera.request();
@ -130,11 +131,11 @@ class HistoryProvider with ChangeNotifier {
final List<dynamic> blockchainTX =
(result.data['txsHistoryBc']['both']['edges'] as List<dynamic>);
final Map pageInfo = result.data['txsHistoryBc']['both']['pageInfo'];
pageInfo = result.data['txsHistoryBc']['both']['pageInfo'];
fetchMoreCursor = pageInfo['endCursor'];
print(pageInfo['hasPreviousPage']);
print(pageInfo['hasNextPage']);
print('hasPreviousPage: ' + pageInfo['hasPreviousPage'].toString());
print('hasNextPage: ' + pageInfo['hasNextPage'].toString());
if (fetchMoreCursor != null) {
opts = FetchMoreOptions(

View File

@ -233,6 +233,7 @@ class HistoryScreen extends StatelessWidget with ChangeNotifier {
indent: 0,
endIndent: 0,
),
// !_historyProvider.pageInfo['hasPreviousPage'] //TODO: fix value of hasPreviousPage
_historyProvider.transBC == null
? Text('Aucune transaction à afficher.')
: loopTransactions(context, result),