mirror of
https://github.com/eclipse-sailing-analytics/sailing-analytics.git
synced 2026-09-30 17:36:40 +00:00
Fixed "Gezappel" of Screen - also fixed wind track positions
This commit is contained in:
1 parent
4e18c943f0
commit
41b540c344
2 files changed
+14
-4
No files matched your search
@@ -96,7 +96,7 @@ class BaseView(object):
|
||||
def currentLeaderboardEvent(self):
|
||||
cev = model.EventImpl.queryOneBy(name=current_leaderboard_event)
|
||||
|
||||
# XXX remove this
|
||||
# XXX remove this - only for tests
|
||||
if not cev:
|
||||
return model.EventImpl.queryBy()[0]
|
||||
|
||||
@@ -113,7 +113,15 @@ class BaseView(object):
|
||||
conf.setCommand(config.SHOW_WIND)
|
||||
conf.setParameters(dict(eventname=race.event, racename=race.name))
|
||||
|
||||
return jsonByUrl(conf)
|
||||
data = jsonByUrl(conf)
|
||||
|
||||
for name in ['WEB', 'EXPEDITION']:
|
||||
if data and data.get(name):
|
||||
expwind = data[name]
|
||||
expwind.reverse()
|
||||
data[name] = expwind
|
||||
|
||||
return data
|
||||
|
||||
def allEvents(self):
|
||||
return model.EventImpl.queryBy()
|
||||
|
||||
@@ -23,7 +23,8 @@
|
||||
<div id="listeners-container">
|
||||
<select id="listeners">
|
||||
<option>Loading....</option>
|
||||
</select>
|
||||
</select> <br/>
|
||||
<div align="right">
|
||||
<input type="button" value="UnPause" onclick="GET('unPauseListener', {tid:$('#listeners option:selected').val()}, loadListeners)"/>
|
||||
|
||||
<input type="button" value="Pause" onclick="GET('pauseListener', {tid:$('#listeners option:selected').val()}, loadListeners)"/>
|
||||
@@ -34,6 +35,7 @@
|
||||
|
||||
<input type="button" value="Stop" onclick="GET('stopListener', {tid: $('#listeners option:selected').val()}, loadListeners)"/>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
@@ -85,7 +87,7 @@
|
||||
GET('configuredListeners', {}, function(data) {
|
||||
options = '';
|
||||
for (d in data) {
|
||||
options += format('<option value="'+data[d].xid+'">{host}:{port} | {eventname} | {racename} | Last Update: {last_update} Paused: {paused} Running: {running}</option>', data[d]);
|
||||
options += format('<option value="'+data[d].xid+'">{host}:{port} | {eventname} | {racename} | U: {last_update} P: {paused}</option>', data[d]);
|
||||
}
|
||||
|
||||
if (options == '')
|
||||
|
||||
Reference in new issue
Block a user