protected bool Deactivate(IMovieStoryArc entity) { // Deactivate it MovieStoryArcsRepository.Deactivate(entity); // Try to Save Changes MovieStoryArcsRepository.SaveChanges(); // Finished! return(true); }
public virtual bool AreEqual(IMovieStoryArcModel model, IMovieStoryArc entity) { return(EntityMapper.AreEqual(model, entity) // MovieStoryArc Properties // <None> // Related Objects && model.MovieId == entity.MovieId && model.StoryArcId == entity.StoryArcId ); }
protected bool Remove(IMovieStoryArc entity) { if (entity == null) { return(true); } // No entity found to remove, consider it passed // Remove it MovieStoryArcsRepository.Remove(entity); // Try to Save Changes MovieStoryArcsRepository.SaveChanges(); // Finished! return(true); }
public virtual IMovieStoryArcModel MapToModelListing(IMovieStoryArc entity, int currentDepth = 1) { currentDepth++; var model = EntityMapper.MapToModelListing <IMovieStoryArc, MovieStoryArcModel>(entity); // MovieStoryArc Properties // <None> // Related Objects model.MovieId = entity.MovieId; model.StoryArcId = entity.StoryArcId; // Return Entity return(model); }
public virtual void MapToEntity(IMovieStoryArcModel model, ref IMovieStoryArc entity, int currentDepth = 1) { currentDepth++; // Assign Base properties EntityMapper.MapToEntity(model, ref entity); // MovieStoryArc Properties // <None> // Related Objects entity.MovieId = model.MovieId; entity.Movie = (Movie)model.Movie?.MapToEntity(); entity.StoryArcId = model.StoryArcId; entity.StoryArc = (StoryArc)model.StoryArc?.MapToEntity(); // Associated Objects // <None> }
public void Update(IMovieStoryArc entity) { Context.SetModified(entity); }
public void Remove(IMovieStoryArc entity) { Context.MovieStoryArcs.Remove((MovieStoryArc)entity); }
public void Deactivate(IMovieStoryArc entity) { entity.Active = false; Update(entity); }
public void Add(IMovieStoryArc entity) { Context.MovieStoryArcs.Add((MovieStoryArc)entity); }
public static bool AreEqual(this IMovieStoryArcModel model, IMovieStoryArc entity) { return(Mapper.AreEqual(model, entity)); }
public static IMovieStoryArcModel MapToModelListing(this IMovieStoryArc entity, int currentDepth = 1) { return(Mapper.MapToModelListing(entity, currentDepth)); }
public static void MapToEntity(this IMovieStoryArcModel model, ref IMovieStoryArc entity, int currentDepth = 1) { Mapper.MapToEntity(model, ref entity, currentDepth); }
protected bool Deactivate(IMovieStoryArc entity) { // Deactivate it MovieStoryArcsRepository.Deactivate(entity); // Try to Save Changes MovieStoryArcsRepository.SaveChanges(); // Finished! return true; }
protected bool Remove(IMovieStoryArc entity) { if (entity == null) { return true; } // No entity found to remove, consider it passed // Remove it MovieStoryArcsRepository.Remove(entity); // Try to Save Changes MovieStoryArcsRepository.SaveChanges(); // Finished! return true; }