Exemple #1
0
        public static CountryTax Create(Guid id, TaxType type, Country country, decimal percentage)
        {
            CountryTax countryTax = Create(type, country, percentage);

            countryTax.Id = id;
            return(countryTax);
        }
        public static CountryTax Create(Guid id, TaxType type, Country country, decimal percentage)
        {
            CountryTax countryTax = new CountryTax()
            {
                Id         = id,
                Country    = country,
                Percentage = percentage,
                Type       = type
            };

            DomainEvents.Raise <CountryTaxCreated>(new CountryTaxCreated()
            {
                CountryTax = countryTax
            });

            return(countryTax);
        }