git-svn-id: http://www.winterrodeln.org/svn/servermediawiki/trunk/wradmin@767
7aebc617-e5e2-0310-91dc-
80fb5f6d2477
description='Administrative Interface for Winterrodeln',
author='Philipp Spitzer',
author_email='philipp.spitzer@winterrodeln.org',
description='Administrative Interface for Winterrodeln',
author='Philipp Spitzer',
author_email='philipp.spitzer@winterrodeln.org',
def update(self):
"Updates the wrsledruncache table from the wiki"
def update(self):
"Updates the wrsledruncache table from the wiki"
- from wradmin.model import page_table as page, wrsleddingcache_table1_3 as wrsledruncache, categorylinks_table as categorylinks, revision_table as revision, text_table as text
+ from wradmin.model import page_table as page, wrsledruncache_table as wrsledruncache, categorylinks_table as categorylinks, revision_table as revision, text_table as text
from sqlalchemy.sql import select
c = model.meta.Session.connection()
from sqlalchemy.sql import select
c = model.meta.Session.connection()
# Old table definition
# - version 1.3 (changes made from version 1.2)
# Old table definition
# - version 1.3 (changes made from version 1.2)
-# wrsleddingcache_table1_3 = sa.Table("wrsleddingcache1_3", meta.metadata,
-wrsleddingcache_table1_3 = sa.Table("wrsleddingcache", meta.metadata,
+wrsleddingcache_table1_3 = sa.Table("wrsleddingcache1_3", meta.metadata,
sa.Column("page_id", types.Integer, primary_key=True),
sa.Column("page_title", types.Unicode(255)),
sa.Column("position_latitude", types.Float),
sa.Column("page_id", types.Integer, primary_key=True),
sa.Column("page_title", types.Unicode(255)),
sa.Column("position_latitude", types.Float),
orm.mapper(WrReport, wrreport_table)
# We could add a relation but we don't need it yet:
# orm.mapper(WrSledrunCache, wrsledruncache_table, properties = {'reports': orm.relation(WrReport, backref='sledding')})
orm.mapper(WrReport, wrreport_table)
# We could add a relation but we don't need it yet:
# orm.mapper(WrSledrunCache, wrsledruncache_table, properties = {'reports': orm.relation(WrReport, backref='sledding')})
-orm.mapper(WrSledrunCache, wrsleddingcache_table1_3) # TODO: Change to wrsledruncache_table
+orm.mapper(WrSledrunCache, wrsledruncache_table)
orm.mapper(WrInnCache, wrinncache_table)
orm.mapper(WrInnCache, wrinncache_table)
<th>Gehzeit</th>
<th>Höhe (oben)</th>
<th>Höhe (unten)</th>
<th>Gehzeit</th>
<th>Höhe (oben)</th>
<th>Höhe (unten)</th>
+ <th>Aufstieg möglich</th>
<th>Aufstieg getrennt</th>
<th>Lift</th>
<th>Licht</th>
<th>Aufstieg getrennt</th>
<th>Lift</th>
<th>Licht</th>
<td>${s.walkup_time}</td>
<td>${s.top_elevation}</td>
<td>${s.bottom_elevation}</td>
<td>${s.walkup_time}</td>
<td>${s.top_elevation}</td>
<td>${s.bottom_elevation}</td>
+ <td>${h.bool(s.walkup_possible)}</td>
<td>${h.tristate_float(s.walkup_separate)}</td>
<td>${h.bool(s.lift)}</td>
<td>${h.tristate_float(s.night_light)}</td>
<td>${h.tristate_float(s.walkup_separate)}</td>
<td>${h.bool(s.lift)}</td>
<td>${h.tristate_float(s.night_light)}</td>
<th>Höhe (unten)</th>
<td>${c.sledding.bottom_elevation}</td>
</tr>
<th>Höhe (unten)</th>
<td>${c.sledding.bottom_elevation}</td>
</tr>
+ <tr>
+ <th>Aufstieg möglich</th>
+ <td>${h.bool(c.sledding.walkup_possible)}</td>
+ </tr>
<tr>
<th>Aufstieg getrennt</th>
<td>${h.tristate_float(c.sledding.walkup_separate)}</td>
<tr>
<th>Aufstieg getrennt</th>
<td>${h.tristate_float(c.sledding.walkup_separate)}</td>