summaryrefslogtreecommitdiff
path: root/templates/layouts/default.html.ep
blob: 8600b8f0339edf7d47def2ba760e324cfca3c775 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
<!DOCTYPE html>
<html>
<head>
	<title><%= $title %></title>
	<meta charset="utf-8">
% if ($self->stash('refresh_interval')) {
	<meta http-equiv="refresh" content="<%= $self->stash('refresh_interval') %>"/>
% }


	%= stylesheet '/default.css'
	%= javascript '/jquery-1.10.2.min.js'
	%= javascript '/marquee.js'
	%= javascript begin
	$(function () {  $('marquee').marquee() });
	% end
</head>
<body style="<%= ($hide_opts ? 'margin: 0; padding: 0;' : q{}) %>">

% if (my $error = stash 'error') {
<div class="error">Received an error from the backend service:</div>
<div>
<pre>
%= $error
</pre>
</div>
% }

%= content

% if (not $hide_opts) {
<div class="input-field">


%= form_for _redirect => begin
<div>
  <div class="field">
    <div class="desc">Station name</div>
    <div>
% if (stash('stationlist')) {
      %= select_field station => stash('stationlist')
% }
% else {
      %= text_field 'station'
% }
      %= submit_button 'Display'
    </div>
  </div>
  <div class="break"></div>
  <span class="optional">optional:</span>
  <div class="field">
    <div class="desc">
      only display routes via
    </div>
    <div>
      %= text_field 'via'
    </div>
  </div>
  <div class="field">
    <div class="desc">
      on platforms
    </div>
    <div>
      %= text_field 'platforms'
    </div>
  </div>
  <div class="field">
    <div class="desc">
      hide delay &lt; 5 minutes
    </div>
    <div>
      %= check_box 'hidelowdelay' => 1
    </div>
  </div>
  <div class="field">
    <div class="desc">
      display type
    </div>
    <div>
      %= select_field mode => [['combined' => 'multi'], ['platform' => 'single'], ['non-DB' => 'clean']]
    </div>
  </div>
  <div class="field">
    <div class="desc">
      backend
    </div>
    <div>
      %= select_field backend => [['RIS' => 'ris'], ['IRIS' => 'iris']]
    </div>
  </div>
  <div class="field">
    <div class="desc">
      hide input fields
    </div>
    <div>
      %= check_box 'hide_opts' => 1
    </div>
  </div>
</div>
% end

</div> <!-- input-field -->

<div class="notes">
<span class="notes">notes:</span>
<ul>
<li>Umlauts do not work reliably. Try either ä → ae or ä → a</li>
</ul>
</div> <!-- notes -->

<div class="notes">
<span class="notes">examples:</span>
<ul>
<li><a href="/Essen%20Hbf">Essen HBf</a> (RIS, combined table)</li>
<li><a href="/Dortmund/Bochum%7CHamm">Dortmund HBf</a> (RIS, combined table,
only routes via Bochum or Hamm)</li>
<li><a href="/Dortmund%20Uni?mode=clean&backend=iris">Dortmund Universit&auml;t</a> (IRIS, mobile view)</li>
<li><a href="/KD?mode=single&backend=iris">D&uuml;sseldorf HBf</a> (IRIS, platform view)</li>
</ul>
</div>

<div class="notes">
<span class="notes">see also:</span>
<ul>
<li><a href="http://reiseauskunft.bahn.de/bin/bhftafel.exe/dn">DeutscheBahn RIS</a></li>
<li><a href="https://iris.noncd.db.de/wbt/js/index.html?typ=ab&amd;style=qrab&amp;bhf=EE&amp;SecLang=&amp;Zeilen=40&amp;footer=0&amp;disrupt=1"
>DeutscheBahn IRIS</a> (see <a href="http://www.db-netz.de/file/2361656/data/betriebsstellen.pdf">betriebsstellen.pdf</a>)</li>
<li><a href="http://www.frubi.net/iris/?station=Essen%20HBf">frubi.net arrival/departure monitor</a></li>
<li><a href="http://vrrf.finalrewind.org/">vrr-fakedisplay</a></li>
</ul>
</div> <!-- notes -->

<div class="about">
<a href="http://finalrewind.org/projects/db-fakedisplay/">db-fakedisplay</a>
v<%= $version %>
</div>
% }

</body>
</html>