From 79e2387da4b8b351d1f19c716a975c94d8dd4e78 Mon Sep 17 00:00:00 2001 From: pavelbannov Date: Wed, 6 May 2020 10:20:10 +0300 Subject: [PATCH] Files: fixed trash folder --- .../Server/Core/Dao/TeamlabDao/FolderDao.cs | 2 ++ products/ASC.Files/Server/Core/FileStorageService.cs | 12 ------------ 2 files changed, 2 insertions(+), 12 deletions(-) diff --git a/products/ASC.Files/Server/Core/Dao/TeamlabDao/FolderDao.cs b/products/ASC.Files/Server/Core/Dao/TeamlabDao/FolderDao.cs index ba8d615ba2..14eca97578 100644 --- a/products/ASC.Files/Server/Core/Dao/TeamlabDao/FolderDao.cs +++ b/products/ASC.Files/Server/Core/Dao/TeamlabDao/FolderDao.cs @@ -926,6 +926,8 @@ namespace ASC.Files.Core.Data tx.Commit(); //Commit changes } + FilesDbContext.SaveChanges(); + return newFolderId; } diff --git a/products/ASC.Files/Server/Core/FileStorageService.cs b/products/ASC.Files/Server/Core/FileStorageService.cs index 4733fe5ff0..79d81c94f1 100644 --- a/products/ASC.Files/Server/Core/FileStorageService.cs +++ b/products/ASC.Files/Server/Core/FileStorageService.cs @@ -2015,18 +2015,6 @@ namespace ASC.Web.Files.Services.WCFService } } - private static void ParseArrayItems(Dictionary items, out Dictionary folders, out Dictionary files) - { - //TODO:!!!!Fix - folders = new Dictionary(); - files = new Dictionary(); - foreach (var item in (items ?? new Dictionary())) - { - if (item.Key.StartsWith("file_")) files.Add(item.Key.Substring("file_".Length), item.Value); - if (item.Key.StartsWith("folder_")) folders.Add(item.Key.Substring("folder_".Length), item.Value); - } - } - private static void ErrorIf(bool condition, string errorMessage) { if (condition) throw new InvalidOperationException(errorMessage);