lihao 4 년 전
부모
커밋
b233436714
1개의 변경된 파일5개의 추가작업 그리고 1개의 파일을 삭제
  1. 5 1
      gx_api/GxPress/Repository/GxPress.Repository.Implement/RecordFolder/RecordFolderRepository.cs

+ 5 - 1
gx_api/GxPress/Repository/GxPress.Repository.Implement/RecordFolder/RecordFolderRepository.cs

@@ -68,7 +68,11 @@ namespace GxPress.Repository.Implement.RecordFolder
         /// <returns></returns>
         public async Task<bool> AddAsync(int folderType, int userId, int folderId)
         {
-            var recordFolder = await _repository.GetAsync(Q.Where(nameof(Entity.RecordFolder.RecordFolder.UserId), userId).Where(nameof(Entity.RecordFolder.RecordFolder.FolderType), folderType));
+            var query = Q.NewQuery();
+            query.Where(nameof(Entity.RecordFolder.RecordFolder.UserId), userId);
+            query.Where(nameof(Entity.RecordFolder.RecordFolder.FolderType), folderType);
+            query.Where(nameof(Entity.RecordFolder.RecordFolder.FolderId), folderId);
+            var recordFolder = await _repository.GetAsync(query);
             var middle = await _middleRepository.GetAsync(folderId);
             if (middle == null)
                 return true;