Whatever.

This commit is contained in:
M 2021-03-22 19:38:55 +02:00
parent b20246ad89
commit 23f73df391
3 changed files with 18 additions and 12 deletions

View file

@ -4,7 +4,7 @@ import 'package:cake_wallet/exchange/trade_state.dart';
import 'package:http/http.dart';
Future<Order> findOrderById(String id) async {
final orderUrl = 'https://api.testwyre.com/v3/orders/' + id;
final orderUrl = 'https://api.sendwyre.com/v3/orders/' + id;
final orderResponse = await get(orderUrl);
@ -20,7 +20,7 @@ Future<Order> findOrderById(String id) async {
DateTime.fromMillisecondsSinceEpoch(createdAtRaw).toLocal();
final transferUrl =
'https://api.testwyre.com/v2/transfer/' + transferId + '/track';
'https://api.sendwyre.com/v2/transfer/' + transferId + '/track';
final transferResponse = await get(transferUrl);

View file

@ -144,19 +144,25 @@ class DashboardPage extends BasePage {
onClick: walletViewModel.isRunningWebView
? null
: () async {
walletViewModel.isRunningWebView = true;
final url = await walletViewModel.getWyreUrl();
if (url.isNotEmpty) {
await Navigator.of(context)
.pushNamed(Routes.wyre, arguments: url);
try {
walletViewModel.isRunningWebView = true;
final url = await walletViewModel.getWyreUrl();
if (url.isNotEmpty) {
await Navigator.of(context)
.pushNamed(Routes.wyre, arguments: url);
final orderId = walletViewModel.ordersStore.orderId;
final orderId = walletViewModel.ordersStore
.orderId;
if (orderId.isNotEmpty) {
await walletViewModel.saveOrder(orderId);
if (orderId.isNotEmpty) {
await walletViewModel.saveOrder(orderId);
}
}
walletViewModel.isRunningWebView = false;
} catch(e) {
print(e.toString());
walletViewModel.isRunningWebView = false;
}
walletViewModel.isRunningWebView = false;
})
],
)),

View file

@ -52,7 +52,7 @@ abstract class OrderDetailsViewModelBase with Store {
void _updateItems() {
final dateFormat = DateFormatter.withCurrentLocal();
final buildURL =
'https://dashboard-test.testwyre.com/track/${order.transferId}';
'https://api.sendwyre.com/v2/transfer/${order.transferId}/track';
items?.clear();