public static Address ToWebModel(this CartModule.Client.Model.Address address) { var addressWebModel = new Address(); addressWebModel.InjectFrom(address); addressWebModel.Type = (AddressType)Enum.Parse(typeof(AddressType), address.Type, true); return(addressWebModel); }
public static CartModule.Client.Model.Address ToCartServiceModel(this Address address) { var addressServiceModel = new CartModule.Client.Model.Address(); addressServiceModel.InjectFrom(address); addressServiceModel.Type = address.Type.ToString(); return(addressServiceModel); }