@@ -59,7 +59,7 @@ namespace Learun.Application.OA.File.FileInfo
var strSql = new StringBuilder();
string folderCondition = "";
string fileCondition = "";
if (!string.IsNullOrEmpty(folderId))
if (!string.IsNullOrEmpty(folderId)&&folderId!="null" )
{
folderCondition = " AND F_ParentId = @folderId";
fileCondition = " AND F_FolderId = @folderId";
@@ -70,15 +70,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 adms7ultimate2_黑龙江艺术.dbo.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 ,