public static Stores.Store ToRepository(this DtoStore dto) { if (dto == null) { return(null); } var model = new Stores.Store() { Id = dto.Id, MaxDistance = dto.MaxDistance, Document = dto.Document, Email = dto.Email, Name = dto.Name, PasswordHash = dto.PasswordHash, Profit = dto.Profit }; return(model); }
public static DtoStore ToDTO(this Stores.Store model) { if (model == null) { return(null); } var dto = new DtoStore() { Id = model.Id, Document = model.Document, Email = model.Email, Name = model.Name, MaxDistance = model.MaxDistance, PasswordHash = model.PasswordHash, Profit = model.Profit }; return(dto); }