Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
nmaas Platform
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Terraform modules
Analyze
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
nmaas
nmaas Platform
Commits
0767bf90
Commit
0767bf90
authored
1 year ago
by
Łukasz Łopatowski
Browse files
Options
Downloads
Plain Diff
Merge branch 'develop' of
https://gitlab.software.geant.org/nmaas/nmaas-platform
into develop
parents
4728e61c
76a0a03e
No related branches found
No related tags found
No related merge requests found
Pipeline
#87474
passed
1 year ago
Stage: test
Stage: sonar
Stage: build
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/main/java/net/geant/nmaas/portal/api/market/ApplicationController.java
+21
-0
21 additions, 0 deletions
.../geant/nmaas/portal/api/market/ApplicationController.java
with
21 additions
and
0 deletions
src/main/java/net/geant/nmaas/portal/api/market/ApplicationController.java
+
21
−
0
View file @
0767bf90
...
@@ -68,6 +68,15 @@ public class ApplicationController extends AppBaseController {
...
@@ -68,6 +68,15 @@ public class ApplicationController extends AppBaseController {
private
ApplicationView
application
;
private
ApplicationView
application
;
}
}
@AllArgsConstructor
@NoArgsConstructor
@Getter
@Setter
public
static
class
ApplicationDTOVersionList
{
private
ApplicationBaseView
applicationBase
;
private
List
<
ApplicationView
>
applications
;
}
private
final
ApplicationEventPublisher
eventPublisher
;
private
final
ApplicationEventPublisher
eventPublisher
;
private
final
RatingRepository
ratingRepository
;
private
final
RatingRepository
ratingRepository
;
...
@@ -198,6 +207,18 @@ public class ApplicationController extends AppBaseController {
...
@@ -198,6 +207,18 @@ public class ApplicationController extends AppBaseController {
);
);
}
}
@GetMapping
(
value
=
"/base/allversions/{id}"
)
@Transactional
public
ApplicationDTOVersionList
getApplicationDTOWithAllVersions
(
@PathVariable
Long
id
)
{
ApplicationBase
base
=
appBaseService
.
getBaseApp
(
id
);
List
<
Application
>
versionList
=
this
.
applicationService
.
findAll
().
stream
().
filter
(
app
->
app
.
getName
().
equalsIgnoreCase
(
base
.
getName
())).
collect
(
Collectors
.
toList
());
return
new
ApplicationDTOVersionList
(
modelMapper
.
map
(
base
,
ApplicationBaseView
.
class
),
versionList
.
stream
().
map
(
app
->
modelMapper
.
map
(
app
,
ApplicationView
.
class
)).
collect
(
Collectors
.
toList
())
);
}
@GetMapping
(
value
=
"/versions/{id}"
)
@GetMapping
(
value
=
"/versions/{id}"
)
@Transactional
@Transactional
public
Set
<
ApplicationVersion
>
getApplicationVersion
(
@PathVariable
Long
id
)
{
public
Set
<
ApplicationVersion
>
getApplicationVersion
(
@PathVariable
Long
id
)
{
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment