Esempio n. 1
0
        public void Update(Project item)
        {
            ProjectEntity oldProjectEntity = projectRepository.GetItem(item.Id);

            if (oldProjectEntity == null)
            {
                return;
            }

            ProjectEntity projectEntity = mapper.Map <Project, ProjectEntity>(
                item, oldProjectEntity, options => options
                .ConfigureMap()
                .ForMember(proj => proj.Context, mo => mo.Ignore())
                );

            projectRepository.Update(projectEntity);

            elastic.UpdateProjectData(mapper.Map <ElasticProjectData>(item));
        }