diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.OA/File/FileInfo/FileInfoService.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.OA/File/FileInfo/FileInfoService.cs index ef802bbad..0eb33dba8 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.OA/File/FileInfo/FileInfoService.cs +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.OA/File/FileInfo/FileInfoService.cs @@ -128,15 +128,17 @@ namespace Learun.Application.OA.File.FileInfo fileCondition = " AND F_FolderId = '0'"; } strSql.Append(@"SELECT * - FROM ( SELECT F_FolderId AS F_FileId , + FROM ( SELECT a.F_FolderId AS F_FileId , F_ParentId AS F_FolderId , F_FolderName AS F_FileName , - '' AS F_FileSize , + b.filesize AS F_FileSize , 'folder' AS F_FileType , - F_CreateUserId, + a.F_CreateUserId, F_ModifyDate, F_IsShare - FROM LR_OA_FileFolder where F_DeleteMark = 0"); + FROM LR_OA_FileFolder a "); + strSql.Append(" left join (select a.f_createuserid,a.f_folderid,sum(convert(float, f_filesize)) as filesize from LR_OA_FileInfo a group by a.f_createuserid,a.f_folderid having a.f_createuserid='System') b on b.f_folderid=a.f_folderid "); + strSql.Append(" where F_DeleteMark = 0 "); strSql.Append(folderCondition); strSql.Append(" UNION "); strSql.Append(@"SELECT F_FileId ,