From 052430d97cb2139ce5188b616b939134267ce872 Mon Sep 17 00:00:00 2001 From: George Kalampokis Date: Thu, 9 Jul 2020 15:02:16 +0300 Subject: [PATCH] Minor fixes --- .../java/eu/eudat/logic/managers/DataManagementPlanManager.java | 2 +- dmp-frontend/src/app/ui/dmp/overview/dmp-overview.component.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/dmp-backend/web/src/main/java/eu/eudat/logic/managers/DataManagementPlanManager.java b/dmp-backend/web/src/main/java/eu/eudat/logic/managers/DataManagementPlanManager.java index ded7530db..5b6d640a2 100644 --- a/dmp-backend/web/src/main/java/eu/eudat/logic/managers/DataManagementPlanManager.java +++ b/dmp-backend/web/src/main/java/eu/eudat/logic/managers/DataManagementPlanManager.java @@ -316,7 +316,7 @@ public class DataManagementPlanManager { authItems = items; } CompletableFuture> versionFuture = authItems.withHint(HintedModelFactory.getHint(VersionListingModel.class)) - .orderBy(((builder, root) -> builder.asc(root.get("version")))) + .orderBy(((builder, root) -> builder.desc(root.get("version")))) .selectAsync(item -> new VersionListingModel().fromDataModel(item)) .whenComplete(((versionListingModels, throwable) -> versions.addAll(versionListingModels))); diff --git a/dmp-frontend/src/app/ui/dmp/overview/dmp-overview.component.ts b/dmp-frontend/src/app/ui/dmp/overview/dmp-overview.component.ts index cadb8c4ed..945289876 100644 --- a/dmp-frontend/src/app/ui/dmp/overview/dmp-overview.component.ts +++ b/dmp-frontend/src/app/ui/dmp/overview/dmp-overview.component.ts @@ -379,7 +379,7 @@ export class DmpOverviewComponent extends BaseComponent implements OnInit { } getAllVersions(dmp: DmpOverviewModel) { - this.dmpService.getAllVersions(dmp.id) + this.dmpService.getAllVersions(dmp.groupId) .pipe(takeUntil(this._destroyed)) .subscribe(items => { this.versions = items;