private Catalog MapModelToEntity(CatalogBO model) { Catalog entity = new Catalog { CatalogType = model.CatalogType, Description = model.Description, Id = model.Id, Name = model.Name, Updated = model.Updated }; return(entity); }
private CatalogBO MapEntityToModel(Catalog entity) { CatalogBO model = new CatalogBO { CatalogType = entity.CatalogType, Description = entity.Description, Id = entity.Id, Name = entity.Name, Updated = entity.Updated }; return(model); }
public async Task <CatalogBO> AddAsync(CatalogBO model) { Catalog result = await _commands.AddAsync(MapModelToEntity(model)); return(MapEntityToModel(result)); }