mirror of
https://github.com/brmlab/povoden.git
synced 2025-06-08 02:04:01 +02:00
added two more stations
This commit is contained in:
parent
b294b3221f
commit
d5c23d8eb6
3 changed files with 65 additions and 6 deletions
19
Makefile
19
Makefile
|
@ -5,9 +5,18 @@ XMLLINT=xmllint --html --nowarning
|
|||
VODAURL=http://hydro.chmi.cz/hpps/popup_hpps_prfdyn.php?seq=307225
|
||||
VODAIMG1=http://hydro.chmi.cz/hpps/tmp/img/big/307225_H.png
|
||||
VODAIMG2=http://hydro.chmi.cz/hpps/tmp/img/big/307225_Q.png
|
||||
|
||||
VODAURL_MELNIK=http://hydro.chmi.cz/hpps/popup_hpps_prfdyn.php?seq=307081
|
||||
VODAIMG1_MELNIK=http://hydro.chmi.cz/hpps/tmp/img/big/307081_H.png
|
||||
VODAIMG2_MELNIK=http://hydro.chmi.cz/hpps/tmp/img/big/307081_Q.png
|
||||
|
||||
VODAURL_USTI=http://hydro.chmi.cz/hpps/popup_hpps_prfdyn.php?seq=307228
|
||||
VODAIMG1_USTI=http://hydro.chmi.cz/hpps/tmp/img/big/307228_H.png
|
||||
VODAIMG2_USTI=http://hydro.chmi.cz/hpps/tmp/img/big/307228_Q.png
|
||||
|
||||
VODAXPATH=//table[@class="stdstationtbl"]/./tr[3]//table/tr[position()>1]
|
||||
|
||||
# oprion #2
|
||||
# option #2
|
||||
#VODAURL=http://vvv.chmi.cz/hydro/detail_stanice/307225.html
|
||||
#VODAIMG1=http://vvv.chmi.cz/hydro/graph/big/307225_H.png
|
||||
#VODAIMG2=http://vvv.chmi.cz/hydro/graph/big/307225_Q.png
|
||||
|
@ -25,6 +34,14 @@ refresh:
|
|||
wget '$(VODAIMG2)' -O data/prutok_.png
|
||||
wget '$(VODAURL)' -O - | $(XMLLINT) --encode utf8 - | $(XMLLINT) --xpath '$(VODAXPATH)' - > data/table_.html
|
||||
mv data/stav_.png data/stav.png && mv data/prutok_.png data/prutok.png && mv data/table_.html data/table.html
|
||||
wget '$(VODAIMG1_MELNIK)' -O data/stav_melnik_.png
|
||||
wget '$(VODAIMG2_MELNIK)' -O data/prutok_melnik_.png
|
||||
wget '$(VODAURL_MELNIK)' -O - | $(XMLLINT) --encode utf8 - | $(XMLLINT) --xpath '$(VODAXPATH)' - > data/table_melnik_.html
|
||||
mv data/stav_melnik_.png data/stav_melnik.png && mv data/prutok_melnik_.png data/prutok_melnik.png && mv data/table_melnik_.html data/table_melnik.html
|
||||
wget '$(VODAIMG1_USTI)' -O data/stav_usti_.png
|
||||
wget '$(VODAIMG2_USTI)' -O data/prutok_usti_.png
|
||||
wget '$(VODAURL_USTI)' -O - | $(XMLLINT) --encode utf8 - | $(XMLLINT) --xpath '$(VODAXPATH)' - > data/table_usti_.html
|
||||
mv data/stav_usti_.png data/stav_usti.png && mv data/prutok_usti_.png data/prutok_usti.png && mv data/table_usti_.html data/table_usti.html
|
||||
|
||||
refreshdpp:
|
||||
wget $(DOPRAVAURL) -O - | $(XMLLINT) --encode utf8 - > $(DOPRAVATMP)
|
||||
|
|
10
data/.gitignore
vendored
10
data/.gitignore
vendored
|
@ -1,5 +1,5 @@
|
|||
doprava.html
|
||||
doprava.png
|
||||
prutok.png
|
||||
stav.png
|
||||
table.html
|
||||
doprava*.html
|
||||
doprava*.png
|
||||
prutok*.png
|
||||
stav*.png
|
||||
table*.html
|
||||
|
|
42
index.haml
42
index.haml
|
@ -16,6 +16,7 @@
|
|||
%li <a href='kontakty.html'>Kontakty</a>
|
||||
|
||||
.content
|
||||
|
||||
%table.twocolumn
|
||||
%tr
|
||||
%td(style="padding: 16px;")
|
||||
|
@ -33,5 +34,46 @@
|
|||
%th průtok [m<sup>3</sup>s<sup>-1</sup>]
|
||||
%th teplota [°C]
|
||||
=File.read("data/table.html")
|
||||
|
||||
%hr
|
||||
|
||||
%table.twocolumn
|
||||
%tr
|
||||
%td(style="padding: 16px;")
|
||||
.imgstav
|
||||
%img(src="data/stav_melnik.png")
|
||||
.imgprutok
|
||||
%img(src="data/prutok_melnik.png")
|
||||
%td(style="padding: 16px;")
|
||||
%table#legend24h(style="margin: 16px;")
|
||||
=File.read("data/legend.html")
|
||||
%table#table24h
|
||||
%tr
|
||||
%th datum a čas
|
||||
%th stav [cm]
|
||||
%th průtok [m<sup>3</sup>s<sup>-1</sup>]
|
||||
%th teplota [°C]
|
||||
=File.read("data/table_melnik.html")
|
||||
|
||||
%hr
|
||||
|
||||
%table.twocolumn
|
||||
%tr
|
||||
%td(style="padding: 16px;")
|
||||
.imgstav
|
||||
%img(src="data/stav_usti.png")
|
||||
.imgprutok
|
||||
%img(src="data/prutok_usti.png")
|
||||
%td(style="padding: 16px;")
|
||||
%table#legend24h(style="margin: 16px;")
|
||||
=File.read("data/legend.html")
|
||||
%table#table24h
|
||||
%tr
|
||||
%th datum a čas
|
||||
%th stav [cm]
|
||||
%th průtok [m<sup>3</sup>s<sup>-1</sup>]
|
||||
%th teplota [°C]
|
||||
=File.read("data/table_usti.html")
|
||||
|
||||
%hr
|
||||
.footer Data poskytuje Český hydrometeorologický ústav. Bez záruky.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue