mirror of
https://github.com/Such-Software/hash-wallet.git
synced 2026-10-26 06:08:40 +01:00
* commit generated files and remove codegen metadata * remove hive_generator dependency * update dependencies * update intl * update ios project files * update native code * update android deps * update image name in ci * revert impeller * re-ignore min version error * fix cw_decred dependency * update hive in cw_core * fix docker build cache for decred * fix conflict * prevent frozen coins being reset on coin info refresh * fix for makeSecure --------- Co-authored-by: Omar Hatem <omarh.ismail1@gmail.com>
61 lines
1.3 KiB
Dart
61 lines
1.3 KiB
Dart
import 'package:cw_core/hive_type_ids.dart';
|
|
import 'package:hive/hive.dart';
|
|
|
|
part 'template.part.dart';
|
|
|
|
// @HiveType(typeId: Template.typeId)
|
|
class Template extends HiveObject {
|
|
Template(
|
|
{required this.nameRaw,
|
|
required this.isCurrencySelectedRaw,
|
|
required this.addressRaw,
|
|
required this.cryptoCurrencyRaw,
|
|
required this.amountRaw,
|
|
required this.fiatCurrencyRaw,
|
|
required this.amountFiatRaw,
|
|
this.additionalRecipientsRaw});
|
|
|
|
static const typeId = TEMPLATE_TYPE_ID;
|
|
static const boxName = 'Template';
|
|
|
|
// @HiveField(0)
|
|
String? nameRaw;
|
|
|
|
// @HiveField(1)
|
|
String? addressRaw;
|
|
|
|
// @HiveField(2)
|
|
String? cryptoCurrencyRaw;
|
|
|
|
// @HiveField(3)
|
|
String? amountRaw;
|
|
|
|
// @HiveField(4)
|
|
String? fiatCurrencyRaw;
|
|
|
|
// @HiveField(5)
|
|
bool? isCurrencySelectedRaw;
|
|
|
|
// @HiveField(6)
|
|
String? amountFiatRaw;
|
|
|
|
// @HiveField(7)
|
|
List<Template>? additionalRecipientsRaw;
|
|
|
|
bool get isCurrencySelected => isCurrencySelectedRaw ?? false;
|
|
|
|
String get fiatCurrency => fiatCurrencyRaw ?? '';
|
|
|
|
String get amountFiat => amountFiatRaw ?? '';
|
|
|
|
String get name => nameRaw ?? '';
|
|
|
|
String get address => addressRaw ?? '';
|
|
|
|
String get cryptoCurrency => cryptoCurrencyRaw ?? '';
|
|
|
|
String get amount => amountRaw ?? '';
|
|
|
|
List<Template>? get additionalRecipients => additionalRecipientsRaw;
|
|
}
|