ledger account service basis
This commit is contained in:
@@ -1,16 +1,17 @@
|
||||
import 'package:pshared/data/dto/payment/money.dart';
|
||||
import 'package:pshared/models/payment/money.dart';
|
||||
import 'package:pshared/models/money.dart';
|
||||
|
||||
|
||||
extension MoneyMapper on Money {
|
||||
MoneyDTO toDTO() => MoneyDTO(
|
||||
amount: amount,
|
||||
currency: currency,
|
||||
);
|
||||
amount: amount,
|
||||
currency: currency,
|
||||
);
|
||||
}
|
||||
|
||||
extension MoneyDTOMapper on MoneyDTO {
|
||||
Money toDomain() => Money(
|
||||
amount: amount,
|
||||
currency: currency,
|
||||
);
|
||||
amount: amount,
|
||||
currency: currency,
|
||||
);
|
||||
}
|
||||
@@ -1,5 +1,5 @@
|
||||
import 'package:pshared/data/dto/wallet/balance.dart';
|
||||
import 'package:pshared/data/mapper/wallet/money.dart';
|
||||
import 'package:pshared/data/mapper/money.dart';
|
||||
import 'package:pshared/models/wallet/balance.dart';
|
||||
|
||||
|
||||
|
||||
@@ -1,10 +0,0 @@
|
||||
import 'package:pshared/data/dto/wallet/money.dart';
|
||||
import 'package:pshared/models/wallet/money.dart';
|
||||
|
||||
|
||||
extension MoneyDTOMapper on MoneyDTO {
|
||||
WalletMoney toDomain() => WalletMoney(
|
||||
amount: amount,
|
||||
currency: currency,
|
||||
);
|
||||
}
|
||||
@@ -1,11 +1,12 @@
|
||||
import 'package:pshared/data/dto/wallet/balance.dart';
|
||||
import 'package:pshared/data/dto/wallet/wallet.dart';
|
||||
import 'package:pshared/data/mapper/money.dart';
|
||||
import 'package:pshared/data/mapper/wallet/asset.dart';
|
||||
import 'package:pshared/data/mapper/wallet/balance.dart';
|
||||
import 'package:pshared/data/mapper/wallet/money.dart';
|
||||
import 'package:pshared/models/describable.dart';
|
||||
import 'package:pshared/models/wallet/wallet.dart';
|
||||
|
||||
|
||||
extension WalletDTOMapper on WalletDTO {
|
||||
WalletModel toDomain({WalletBalanceDTO? balance}) => WalletModel(
|
||||
walletRef: walletRef,
|
||||
|
||||
Reference in New Issue
Block a user