preparing for adding positions to document

This commit is contained in:
2025-07-15 21:58:06 +02:00
parent 148c0f27b5
commit e436f09698
14 changed files with 211 additions and 48 deletions

View File

@@ -7,6 +7,7 @@ import static de.srsoftware.umbrella.core.Paths.LIST;
import static de.srsoftware.umbrella.core.exceptions.UmbrellaException.forbidden;
import static de.srsoftware.umbrella.core.exceptions.UmbrellaException.missingFieldException;
import static de.srsoftware.umbrella.project.Constants.CONFIG_DATABASE;
import static java.util.Comparator.comparing;
import com.sun.net.httpserver.HttpExchange;
import de.srsoftware.configuration.Configuration;
@@ -61,7 +62,7 @@ public class ProjectModule extends BaseHandler implements ProjectService {
}
public Collection<Project> listProjects(long companyId, boolean includeClosed) throws UmbrellaException {
return projectDb.list(companyId, includeClosed);
return projectDb.list(companyId, includeClosed).stream().sorted(comparing(Project::name)).toList();
}
private boolean listItems(HttpExchange ex, UmbrellaUser user) throws IOException, UmbrellaException {