Skip to content

Commit

Permalink
fixed permissions issue for #1253
Browse files Browse the repository at this point in the history
  • Loading branch information
j-dimension committed Nov 4, 2024
1 parent 876fb82 commit c44c36c
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -927,7 +927,7 @@ public String export(ArchiveFileBean dto, Date lastModified) throws Exception {
List<CaseFolder> hierarchy = new ArrayList<>();
if (db.getFolder() != null) {
if(!folderHierarchies.containsKey(db.getFolder().getId())) {
hierarchy=caseFacade.getFolderHierarchy(db.getFolder().getId());
hierarchy=caseFacade.getFolderHierarchyUnrestricted(db.getFolder().getId());
folderHierarchies.put(db.getFolder().getId(), hierarchy);
}
hierarchy=folderHierarchies.get(db.getFolder().getId());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4560,6 +4560,16 @@ public DocumentFolderTemplate getFolderTemplateById(String id) {
return this.folderTemplateFacade.find(id);
}

/**
* Returns a list of folder representing a hierarchy. First element in the list is the root folder.
* @param folderId
* @return
*/
@Override
public List<CaseFolder> getFolderHierarchyUnrestricted(String folderId) {
return getFolderHierarchyImpl(folderId);
}

/**
* Returns a list of folder representing a hierarchy. First element in the list is the root folder.
* @param folderId
Expand All @@ -4568,6 +4578,10 @@ public DocumentFolderTemplate getFolderTemplateById(String id) {
@Override
@RolesAllowed({"loginRole"})
public List<CaseFolder> getFolderHierarchy(String folderId) {
return getFolderHierarchyImpl(folderId);
}

private List<CaseFolder> getFolderHierarchyImpl(String folderId) {
List<CaseFolder> hierarchy=new ArrayList<>();
if(folderId==null)
return hierarchy;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -793,6 +793,7 @@ public interface ArchiveFileServiceLocal {
DocumentFolderTemplate getFolderTemplateById(String id);

List<CaseFolder> getFolderHierarchy(String folderId);
List<CaseFolder> getFolderHierarchyUnrestricted(String folderId);

void purgeDocumentBin() throws Exception;

Expand Down

0 comments on commit c44c36c

Please sign in to comment.