CAKE-306 | applied _saveOrder() to buy_webview_page.dart; fixed moonpay_buy_provider.dart and wyre_buy_provider.dart; canceled timers on exchange_trade_page.dart, order_details_page.dart and trade_details_page.dart; reworked pre_order_page.dart

This commit is contained in:
OleksandrSobol
2021-04-15 20:10:23 +03:00
parent 697fc7f5a5
commit 1c976bfaa1
12 changed files with 238 additions and 171 deletions
+4
View File
@@ -29,6 +29,7 @@ abstract class BuyViewModelBase with Store {
.toList();
isRunning = false;
isDisabled = true;
isShowProviderButtons = false;
}
final Box<Order> ordersSource;
@@ -51,6 +52,9 @@ abstract class BuyViewModelBase with Store {
@observable
bool isDisabled;
@observable
bool isShowProviderButtons;
WalletType get type => wallet.type;
double get doubleAmount => buyAmountViewModel.doubleAmount;
@@ -45,7 +45,7 @@ abstract class ExchangeTradeViewModelBase with Store {
_updateTrade();
_timer = Timer.periodic(Duration(seconds: 20), (_) async => _updateTrade());
timer = Timer.periodic(Duration(seconds: 20), (_) async => _updateTrade());
}
final WalletBase wallet;
@@ -71,7 +71,7 @@ abstract class ExchangeTradeViewModelBase with Store {
ExchangeProvider _provider;
Timer _timer;
Timer timer;
@action
Future confirmSending() async {
+2 -2
View File
@@ -39,7 +39,7 @@ abstract class TradeDetailsViewModelBase with Store {
_updateTrade();
_timer = Timer.periodic(Duration(seconds: 20), (_) async => _updateTrade());
timer = Timer.periodic(Duration(seconds: 20), (_) async => _updateTrade());
}
final Box<Trade> trades;
@@ -52,7 +52,7 @@ abstract class TradeDetailsViewModelBase with Store {
ExchangeProvider _provider;
Timer _timer;
Timer timer;
@action
Future<void> _updateTrade() async {