plugin
upstream
Templates in the website are disabled now. Editing them will not have any effect on the live website.
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
|
$def with (path="", limit=50, use_repr=False)
$ path = query_param("path", path)
$ page = safeint(query_param("page", "0"))
$ pages = list_pages(path, limit=limit, offset=page * limit)
<!--islist-->
<div class="contenttext">
<ul>
$for p in pages:
$if p.type.key != '/type/delete':
$if use_repr:
<li>$:thingrepr(p)</li>
$else:
<li><a href="$homepath()$p.key">$p.key</a></li>
</ul>
</div>
<div class="copyright-footer">
$if page != 0:
← <a href="$:changequery(page=page - 1)" rel="nofollow">$_.prev</a>
$if len(pages) == limit:
... <a href="$:changequery(page=page + 1)" rel="nofollow">$_.next</a> →
<div> |
Debug Stats
SUMMARY
total: {'count': 0, 'unaccounted': 0.086714744567871094, 'time': 0.15376091003417969}
memcache.get: {'count': 5, 'time': 0.013149023056030273}
infobase: {'count': 3, 'time': 0.051080226898193359}
memcache.set: {'count': 1, 'time': 0.0012528896331787109}
memcache.get_multi: {'count': 1, 'time': 0.00156402587890625}
Details
memcache.get 0.00189089775085
{'hit': True, 'key': u'/macros/PageList'}
memcache.get 0.0012800693512
{'hit': False, 'key': 'd/macros/PageList'}
infobase 0.0167140960693
{'path': '/openlibrary.org/versions', 'data': {'query': '{"limit": 1, "key": "/macros/PageList", "offset": 9}'}, 'method': 'GET'}
infobase 0.0181660652161
{'path': '/openlibrary.org/versions', 'data': {'query': '{"limit": 4, "key": "/macros/PageList", "offset": 0}'}, 'method': 'GET'}
memcache.get 0.00100517272949
{'hit': False, 'key': 'd/macros/PageList'}
memcache.set 0.00125288963318
{'key': 'd/macros/PageList'}
memcache.get_multi 0.00156402587891
{'found': 3}
memcache.get 0.00113797187805
{'hit': True, 'key': u'/type/macro'}
infobase 0.0162000656128
{'path': '/openlibrary.org/versions', 'data': {'query': '{"limit": 1, "key": "/macros/PageList", "offset": 0}'}, 'method': 'GET'}
memcache.get 0.00783491134644
{'hit': True, 'key': 'inlibrary.libraries-hash'}