public static ContosoUniversity.DAL.SalesModel.Salon ToEntity(this SalonDto source) { if (source == null) { return(null); } var target = new ContosoUniversity.DAL.SalesModel.Salon(); // Properties target.ModelName = source.ModelName; target.BrandId = source.BrandId; target.ManufactureYear = source.ManufactureYear; target.Id = source.Id; target.SalonType = source.SalonType; target.description = source.description; // User-defined partial method OnEntityCreating(source, target); return(target); }
public static SalonDto ToDtoWithRelated(this ContosoUniversity.DAL.SalesModel.Salon source, int level) { if (source == null) { return(null); } var target = new SalonDto(); // Properties target.ModelName = source.ModelName; target.BrandId = source.BrandId; target.ManufactureYear = source.ManufactureYear; target.Id = source.Id; target.SalonType = source.SalonType; target.description = source.description; // User-defined partial method OnDtoCreating(source, target); return(target); }
static partial void OnEntityCreating(SalonDto source, ContosoUniversity.DAL.SalesModel.Salon target);
public static SalonDto ToDto(this ContosoUniversity.DAL.SalesModel.Salon source) { return(source.ToDtoWithRelated(0)); }
static partial void OnDtoCreating(ContosoUniversity.DAL.SalesModel.Salon source, SalonDto target);