()
| 211 | } |
| 212 | |
| 213 | func (b *CreateBalance) ToBalance() model.Balance { |
| 214 | allocationStrategy := b.AllocationStrategy |
| 215 | if allocationStrategy == "" { |
| 216 | allocationStrategy = "FIFO" |
| 217 | } |
| 218 | return model.Balance{LedgerID: b.LedgerId, IdentityID: b.IdentityId, Currency: b.Currency, MetaData: b.MetaData, CurrencyMultiplier: b.Precision, TrackFundLineage: b.TrackFundLineage, AllocationStrategy: allocationStrategy} |
| 219 | } |
| 220 | |
| 221 | func (b *CreateBalanceMonitor) ToBalanceMonitor() model.BalanceMonitor { |
| 222 | return model.BalanceMonitor{BalanceID: b.BalanceId, Condition: model.AlertCondition{ |
no outgoing calls