protected virtual MonetaryTotal GetAnticipatedMonetaryTotal(ActiveCommerce.Orders.Legacy.Order source) { Assert.ArgumentNotNull(source, "source"); Assert.IsNotNull(source.Currency, "currency"); var monetaryTotal = OrderFactory.CreateMonetaryTotal(); var totals = source.Totals; monetaryTotal.AllowanceTotalAmount = OrderFactory.CreateAmount(totals.DiscountExVat, source.Currency.Code); monetaryTotal.ChargeTotalAmount = OrderFactory.CreateAmount(source.ShippingPrice, source.Currency.Code); monetaryTotal.LineExtensionAmount = OrderFactory.CreateAmount(totals.PriceExVat, source.Currency.Code); monetaryTotal.PayableAmount = OrderFactory.CreateAmount(totals.TotalPriceIncVat, source.Currency.Code); monetaryTotal.PayableRoundingAmount = OrderFactory.CreateAmount(0M, source.Currency.Code); monetaryTotal.PrepaidAmount = OrderFactory.CreateAmount(0M, source.Currency.Code); monetaryTotal.TaxExclusiveAmount = OrderFactory.CreateAmount(totals.TotalVat, source.Currency.Code); monetaryTotal.TaxInclusiveAmount = OrderFactory.CreateAmount(totals.PriceExVat + totals.TotalVat, source.Currency.Code); return(monetaryTotal); }