public virtual TEntity Update(TEntity entity, TextFolder folder) { entity.Repository = Repository.Name; entity.FolderName = folder.FullName; entity.SchemaName = folder.SchemaName; ContentEvent.Fire(ContentAction.PreUpdate, entity); TextContentProvider.Update(entity, entity); ContentEvent.Fire(ContentAction.Update, entity); return(entity); }
public virtual TEntity AddSubContent(TEntity entity, TextFolder folder, string parentFolderName, string parentUUID) { entity.Repository = Repository.Name; entity.FolderName = folder.FullName; entity.SchemaName = folder.SchemaName; entity.ParentFolder = parentFolderName; entity.ParentUUID = parentUUID; ContentEvent.Fire(ContentAction.PreAdd, entity); TextContentProvider.Add(entity); ContentEvent.Fire(ContentAction.Add, entity); return(entity); }