Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Karakas
SWP_SS24_Wetterdaten_sammeln
Commits
4c3b8c9e
Commit
4c3b8c9e
authored
Jun 13, 2024
by
Weiser
Browse files
air wuality fix
parent
dc32f29d
Changes
2
Hide whitespace changes
Inline
Side-by-side
frontend/src/components/weather/currentData.js
View file @
4c3b8c9e
...
...
@@ -299,11 +299,7 @@ const Currentdata = (props) => {
<
div
class
=
"
h3
"
>
<
h3
>
Air
Quality
<
/h3
>
<
/div
>
<
input
type
=
"
checkbox
"
id
=
"
air_quality_co
"
className
=
"
checkBoxFilter
"
/>
<
input
type
=
"
checkbox
"
id
=
"
air_quality_co
"
className
=
"
checkBoxFilter
"
/>
<
label
for
=
"
air_quality_co
"
>
Air
Quality
CO
<
/label
>
<
br
/>
<
input
...
...
@@ -588,18 +584,7 @@ const Currentdata = (props) => {
filterArray
.
push
(
"
gust_mph
"
);
}
}
if
(
air_quality_co
||
air_quality_no2
||
air_quality_o3
||
air_quality_so2
||
air_quality_pm2_5
||
air_quality_pm10
||
air_quality_us_epa_index
||
air_quality_gb_defra_index
)
{
filterArray
.
push
(
"
air_quality
"
);
}
console
.
log
(
air_quality_co
);
if
(
air_quality_co
)
{
filterArray
.
push
(
"
co
"
);
}
...
...
@@ -628,7 +613,7 @@ const Currentdata = (props) => {
let
filterString
=
filterArray
.
join
(
"
,
"
);
const
apiUrl
=
`http://localhost:8080/currentweather?q=
${
latitude_text
}
,
${
longitude_text
}
&filter=
${
filterString
}
`
;
console
.
log
(
apiUrl
);
fetch
(
apiUrl
)
.
then
((
response
)
=>
{
if
(
!
response
.
ok
)
{
...
...
src/main/java/io/swagger/model/Current.java
View file @
4c3b8c9e
...
...
@@ -107,7 +107,7 @@ public class Current {
private
BigDecimal
gustKph
=
null
;
@JsonProperty
(
"air_quality"
)
private
WeatherAirQuality
airQuality
=
n
ull
;
private
WeatherAirQuality
airQuality
=
n
ew
WeatherAirQuality
()
;
public
Current
lastUpdatedEpoch
(
Integer
lastUpdatedEpoch
)
{
this
.
lastUpdatedEpoch
=
lastUpdatedEpoch
;
...
...
Write
Preview
Supports
Markdown
0%
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!
Cancel
Please
register
or
sign in
to comment