Changeset 2930
- Timestamp:
- 02/21/07 13:08:12 (2 years ago)
- Files:
-
- sandbox/mscott/SchevoPylonsNav/trunk/schevopylonsnav/controllers/extent_queries.py (modified) (1 diff)
- sandbox/mscott/SchevoPylonsNav/trunk/schevopylonsnav/controllers/extent_transactions.py (modified) (1 diff)
- sandbox/mscott/SchevoPylonsNav/trunk/schevopylonsnav/templates/extent_queries/index.html (modified) (1 diff)
- sandbox/mscott/SchevoPylonsNav/trunk/schevopylonsnav/tests/functional/test_extent_queries.py (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
sandbox/mscott/SchevoPylonsNav/trunk/schevopylonsnav/controllers/extent_queries.py
r2928 r2930 8 8 # map.resource('extent_query', 'extent_queries') 9 9 10 def index(self, format='html'):10 def index(self, db_id, extent_id, format='html'): 11 11 """GET /: All items in the collection.""" 12 12 # url_for('extent_queries') 13 pass 13 c.dbs = dbs = self.dbs 14 c.db_id = db_id 15 c.db = db = dbs[db_id] 16 c.extent = db.extent(extent_id) 17 return render_response('/extent_queries/index.html') 14 18 15 19 def create(self): sandbox/mscott/SchevoPylonsNav/trunk/schevopylonsnav/controllers/extent_transactions.py
r2926 r2930 1 1 from schevopylonsnav.lib.base import * 2 2 3 3 4 class ExtentTransactionsController(BaseController): sandbox/mscott/SchevoPylonsNav/trunk/schevopylonsnav/templates/extent_queries/index.html
r2928 r2930 1 1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> 2 <html xmlns="http://www.w3.org/1999/xhtml" 3 xmlns:py="http://genshi.edgewall.org/" 4 xmlns:xi="http://www.w3.org/2001/XInclude"> 5 <xi:include href="../master.html"></xi:include> 2 <html> 6 3 <head> 7 <title>${c.extent_plural} in ${c.db_label} -- Navigator</title> 4 <title> 5 Queries 6 ← 7 ${h.plural(c.extent)} 8 ← 9 Extents 10 ← 11 ${h.label(c.db)} 12 ← 13 Databases 14 </title> 8 15 </head> 9 16 <body> 10 17 <div id="breadcrumbs"> 11 <a href="${ c.databases_url}">Databases</a>18 <a href="${h.url_for('databases')}">Databases</a> 12 19 → 13 <a href="${ c.db_url}">${c.db_label}</a>20 <a href="${h.url_for('database', id=c.db_id)}">${h.label(c.db)}</a> 14 21 → 15 <a href="${ c.extents_url}">Extents</a>22 <a href="${h.url_for('extents', db_id=c.db_id)}">Extents</a> 16 23 → 17 <a href="${c.extent_url}">${c.extent_plural}</a> 24 <a href="${h.url_for('extent', db_id=c.db_id, id=c.extent.name)}" 25 >${h.plural(c.extent)}</a> 18 26 → 19 <a href="${h.url_for( )}">Queries</a>27 <a href="${h.url_for('extent_queries', db_id=c.db_id, extent_id=c.extent.name)}">Queries</a> 20 28 </div> 21 29 30 <ul> 31 % for name in c.extent.q: 32 <li> 33 <a href="#">${h.label(c.extent.q[name])}</a> 34 </li> 35 % endfor 36 </ul> 22 37 </body> 23 38 </html> sandbox/mscott/SchevoPylonsNav/trunk/schevopylonsnav/tests/functional/test_extent_queries.py
r2926 r2930 1 1 from schevopylonsnav.tests import * 2 2 3 3 4 class TestExtentQueriesController(TestController): 5 4 6 def test_index(self): 5 pass 6 # response = self.app.get(url_for(controller='extent_queries')) 7 # Test response... 7 response = self.app.get( 8 url_for('extent_queries', db_id='db', extent_id='Foo')) 9 assert 'By Example' in response 10 assert 'Exact Matches' in response
