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
b97b3b34
Commit
b97b3b34
authored
Jun 09, 2024
by
Weiser
Browse files
geht
parent
c62af3ea
Changes
1
Hide whitespace changes
Inline
Side-by-side
frontend/src/components/weather/currentData.js
View file @
b97b3b34
...
...
@@ -103,24 +103,13 @@ const Currentdata = (props) => {
id
=
"
condition_text
"
className
=
"
checkBoxFilter
"
/>
<
label
for
=
"
condition
_text
"
>
Condition
Text
<
/label
>
<
label
for
=
"
condition
"
>
Condition
Text
<
/label
>
<
br
/>
<
input
type
=
"
checkbox
"
id
=
"
condition
_icon
"
id
=
"
condition
"
className
=
"
checkBoxFilter
"
/>
<
label
for
=
"
condition_icon
"
>
Condition
Icon
<
/label
>
<
br
/>
<
input
type
=
"
checkbox
"
id
=
"
condition_code
"
className
=
"
checkBoxFilter
"
/>
<
label
for
=
"
condition_code
"
>
Condition
Code
<
/label
>
<
input
type
=
"
checkbox
"
id
=
"
wind
"
className
=
"
checkBoxFilter
"
/>
<
label
for
=
"
wind
"
>
Wind
<
/label
>
<
br
/>
<
input
type
=
"
checkbox
"
id
=
"
wind_degree
"
...
...
@@ -279,9 +268,7 @@ const Currentdata = (props) => {
const
last_updated
=
document
.
getElementById
(
"
last_updated
"
).
checked
;
const
temp
=
document
.
getElementById
(
"
temp
"
).
checked
;
const
id_day
=
document
.
getElementById
(
"
id_day
"
).
checked
;
const
condition_text
=
document
.
getElementById
(
"
condition_text
"
).
checked
;
const
condition_icon
=
document
.
getElementById
(
"
condition_icon
"
).
checked
;
const
condition_code
=
document
.
getElementById
(
"
condition_code
"
).
checked
;
const
condition
=
document
.
getElementById
(
"
condition_text
"
).
checked
;
const
wind
=
document
.
getElementById
(
"
wind
"
).
checked
;
const
wind_degree
=
document
.
getElementById
(
"
wind_degree
"
).
checked
;
const
wind_dir
=
document
.
getElementById
(
"
wind_dir
"
).
checked
;
...
...
@@ -354,14 +341,8 @@ const Currentdata = (props) => {
if
(
id_day
)
{
filterArray
.
push
(
"
id_day
"
);
}
if
(
condition_text
)
{
filterArray
.
push
(
"
condition_text
"
);
}
if
(
condition_icon
)
{
filterArray
.
push
(
"
condition_icon
"
);
}
if
(
condition_code
)
{
filterArray
.
push
(
"
condition_code
"
);
if
(
condition
)
{
filterArray
.
push
(
"
condition
"
);
}
if
(
wind
)
{
if
(
units
==
"
world
"
)
{
...
...
@@ -426,7 +407,7 @@ const Currentdata = (props) => {
}
if
(
vis
)
{
if
(
units
==
"
world
"
)
{
filterArray
.
push
(
"
vis_m
iles
"
);
filterArray
.
push
(
"
vis_
k
m
"
);
}
else
{
filterArray
.
push
(
"
vis_miles
"
);
}
...
...
@@ -442,28 +423,28 @@ const Currentdata = (props) => {
}
}
if
(
air_quality_co
)
{
filterArray
.
push
(
"
air_quality_
co
"
);
filterArray
.
push
(
"
co
"
);
}
if
(
air_quality_no2
)
{
filterArray
.
push
(
"
air_quality_
no2
"
);
filterArray
.
push
(
"
no2
"
);
}
if
(
air_quality_o3
)
{
filterArray
.
push
(
"
air_quality_
o3
"
);
filterArray
.
push
(
"
o3
"
);
}
if
(
air_quality_so2
)
{
filterArray
.
push
(
"
air_quality_
so2
"
);
filterArray
.
push
(
"
so2
"
);
}
if
(
air_quality_pm2_5
)
{
filterArray
.
push
(
"
air_quality_
pm2_5
"
);
filterArray
.
push
(
"
pm2_5
"
);
}
if
(
air_quality_pm10
)
{
filterArray
.
push
(
"
air_quality_
pm10
"
);
filterArray
.
push
(
"
pm10
"
);
}
if
(
air_quality_us_epa_index
)
{
filterArray
.
push
(
"
air_quality_
us
_
epa
_
index
"
);
filterArray
.
push
(
"
us
-
epa
-
index
"
);
}
if
(
air_quality_gb_defra_index
)
{
filterArray
.
push
(
"
air_quality_
gb
_
defra
_
index
"
);
filterArray
.
push
(
"
gb
-
defra
-
index
"
);
}
let
filterString
=
filterArray
.
join
(
"
,
"
);
...
...
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