public void AddAutodeskFileTreeNode(AutodeskFileTreeNode treeNode, BXCModelEntities context = null) { try { context = context ?? new BXCModelEntities(); var fileNodeRepo = new AutodeskFileTreeNodeRepository(context); fileNodeRepo.InsertNode(treeNode); } catch (Exception ex) { Log.Error("CreateNode Failed", ex); } }
public bool RemoveNodes(IEnumerable<AutodeskFileTreeNode> Nodes, BXCModelEntities context = null) { context = context ?? new BXCModelEntities(); var fileNodeRepo = new AutodeskFileTreeNodeRepository(context); foreach (var node in Nodes) { fileNodeRepo.DeleteNode(node); } fileNodeRepo.SaveGroupChanges(); return true; }
public bool RemoveAllAutodeskFileTreeNodesForLibrary(string library, string owner, BXCModelEntities context = null) { context = context ?? new BXCModelEntities(); var fileNodeRepo = new AutodeskFileTreeNodeRepository(context); var aftreenodes = fileNodeRepo.GetAllByLibrary(library, owner); foreach (var aftreenode in aftreenodes) { fileNodeRepo.DeleteNode(aftreenode); } fileNodeRepo.SaveGroupChanges(); return true; }
public void RemoveAutodeskFileTreeNode(AutodeskFileTreeNode treeNode, BXCModelEntities context = null) { context = context ?? new BXCModelEntities(); var fileNodeRepo = new AutodeskFileTreeNodeRepository(context); fileNodeRepo.DeleteNode(treeNode); }
public IEnumerable<AutodeskFileTreeNode> GetAllTreeNodesForLibrary(string libraryName, string ownerId, BXCModelEntities context = null) { context = context ?? new BXCModelEntities(); var fileNodeRepo = new AutodeskFileTreeNodeRepository(context); return fileNodeRepo.GetAllByLibrary(libraryName, ownerId); }