Robo-advisory-dart/lib/repository/wallet.repository.dart

23 lines
620 B
Dart
Raw Normal View History

import 'package:robo_advisory/injection/dependency_injection.dart';
import 'package:robo_advisory/models/wallet.dart';
class WalletRepository {
static loadWallet() async {
switch (Injector.checkInjector()) {
case Flavor.MOCK:
return Wallet.fromMap(wallerJSON);
default:
// TODO: check how it will work with the API
return Wallet.fromMap(wallerJSON);
}
}
}
final wallerJSON = {
'total_assets': '50,000.00 TL',
'total_turkish_lira': '5000.00 TL',
'total_gold_in_gram': '90.00g XAU',
'total_gold_in_turkish_lira': '45,000.00 TL',
'health_stream_day': 'Day 01'
};