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