Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
PA165 - Airport - project
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Analyze
Contributor analytics
CI/CD analytics
Repository analytics
Insights
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
Ján Macháček
PA165 - Airport - project
Commits
95cae8a1
There was an error fetching the commit references. Please try again later.
Commit
95cae8a1
authored
1 year ago
by
Ján Macháček
Browse files
Options
Downloads
Patches
Plain Diff
report facade refactoring
parent
191bf1cd
No related branches found
No related tags found
No related merge requests found
Pipeline
#
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
report/src/main/java/cz/muni/fi/pa165/report/server/facade/ReportFacadeImpl.java
+3
-5
3 additions, 5 deletions
.../muni/fi/pa165/report/server/facade/ReportFacadeImpl.java
with
3 additions
and
5 deletions
report/src/main/java/cz/muni/fi/pa165/report/server/facade/ReportFacadeImpl.java
+
3
−
5
View file @
95cae8a1
...
@@ -39,6 +39,7 @@ public class ReportFacadeImpl implements ReportFacade{
...
@@ -39,6 +39,7 @@ public class ReportFacadeImpl implements ReportFacade{
List
<
String
>
airportData
=
new
ArrayList
<>();
List
<
String
>
airportData
=
new
ArrayList
<>();
List
<
String
>
cityData
=
new
ArrayList
<>();
List
<
String
>
cityData
=
new
ArrayList
<>();
//Getting airport data and then calling service creating pdf document from them
try
{
try
{
airport
=
airportApi
.
getAirportById
(
id
);
airport
=
airportApi
.
getAirportById
(
id
);
...
@@ -48,7 +49,6 @@ public class ReportFacadeImpl implements ReportFacade{
...
@@ -48,7 +49,6 @@ public class ReportFacadeImpl implements ReportFacade{
+
airport
.
getLocation
());
+
airport
.
getLocation
());
documentData
.
put
(
"airport"
,
airportData
);
documentData
.
put
(
"airport"
,
airportData
);
if
(
airport
.
getCity
()
!=
null
)
{
if
(
airport
.
getCity
()
!=
null
)
{
cityData
.
add
(
"Airport is located in the city "
+
airport
.
getCity
().
getName
());
cityData
.
add
(
"Airport is located in the city "
+
airport
.
getCity
().
getName
());
...
@@ -69,14 +69,13 @@ public class ReportFacadeImpl implements ReportFacade{
...
@@ -69,14 +69,13 @@ public class ReportFacadeImpl implements ReportFacade{
public
Resource
getReportFlightById
(
Long
id
){
public
Resource
getReportFlightById
(
Long
id
){
FlightApi
flightApi
=
new
FlightApi
();
FlightApi
flightApi
=
new
FlightApi
();
FlightDto
flight
;
FlightDto
flight
;
List
<
String
>
flightData
=
new
ArrayList
<>();
List
<
String
>
flightData
=
new
ArrayList
<>();
List
<
String
>
stewardsData
;
List
<
String
>
stewardsData
;
List
<
String
>
airplaneData
=
new
ArrayList
<>();
List
<
String
>
airplaneData
=
new
ArrayList
<>();
List
<
String
>
airportsData
=
new
ArrayList
<>();
List
<
String
>
airportsData
=
new
ArrayList
<>();
//Getting flight data and then calling service creating pdf document from them
try
{
try
{
flight
=
flightApi
.
getFlightById
(
id
);
flight
=
flightApi
.
getFlightById
(
id
);
...
@@ -112,12 +111,11 @@ public class ReportFacadeImpl implements ReportFacade{
...
@@ -112,12 +111,11 @@ public class ReportFacadeImpl implements ReportFacade{
public
Resource
getReportAirplaneById
(
Long
id
){
public
Resource
getReportAirplaneById
(
Long
id
){
AirplaneApi
airplaneApi
=
new
AirplaneApi
();
AirplaneApi
airplaneApi
=
new
AirplaneApi
();
AirplaneDto
airplane
;
AirplaneDto
airplane
;
List
<
String
>
airplaneData
=
new
ArrayList
<>();
List
<
String
>
airplaneData
=
new
ArrayList
<>();
List
<
String
>
airplaneTypeData
=
new
ArrayList
<>();
List
<
String
>
airplaneTypeData
=
new
ArrayList
<>();
//Getting airplane data and then calling service creating pdf document from them
try
{
try
{
airplane
=
airplaneApi
.
getAirplaneById
(
id
);
airplane
=
airplaneApi
.
getAirplaneById
(
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