author | Aurelien Campeas <aurelien.campeas@logilab.fr> |
Thu, 08 Apr 2010 18:05:41 +0200 | |
branch | stable |
changeset 5190 | 73bdc50d6af1 |
parent 5149 | a6bcb3c264fe |
child 5257 | a31fbcfa8c3b |
permissions | -rw-r--r-- |
5149
a6bcb3c264fe
temporary move
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents:
5147
diff
changeset
|
1 |
|
a6bcb3c264fe
temporary move
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents:
5147
diff
changeset
|
2 |
Those are methods you'll find on both request objects and on repository session: |
1714
a721966779be
new book layout, do not compile yet
sylvain.thenault@logilab.fr
parents:
diff
changeset
|
3 |
|
a721966779be
new book layout, do not compile yet
sylvain.thenault@logilab.fr
parents:
diff
changeset
|
4 |
:URL handling: |
3258
6536ee4f37f7
update the documentation
Aurelien Campeas <aurelien.campeas@logilab.fr>
parents:
2476
diff
changeset
|
5 |
* `build_url(*args, **kwargs)`, returns an absolute URL based on the |
6536ee4f37f7
update the documentation
Aurelien Campeas <aurelien.campeas@logilab.fr>
parents:
2476
diff
changeset
|
6 |
given arguments. The *controller* supposed to handle the response, |
6536ee4f37f7
update the documentation
Aurelien Campeas <aurelien.campeas@logilab.fr>
parents:
2476
diff
changeset
|
7 |
can be specified through the first positional parameter (the |
6536ee4f37f7
update the documentation
Aurelien Campeas <aurelien.campeas@logilab.fr>
parents:
2476
diff
changeset
|
8 |
connection is theoretically done automatically :). |
1714
a721966779be
new book layout, do not compile yet
sylvain.thenault@logilab.fr
parents:
diff
changeset
|
9 |
:Data formatting: |
a721966779be
new book layout, do not compile yet
sylvain.thenault@logilab.fr
parents:
diff
changeset
|
10 |
* `format_date(date, date_format=None, time=False)` returns a string for a |
3258
6536ee4f37f7
update the documentation
Aurelien Campeas <aurelien.campeas@logilab.fr>
parents:
2476
diff
changeset
|
11 |
date time according to instance's configuration |
5149
a6bcb3c264fe
temporary move
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents:
5147
diff
changeset
|
12 |
|
3258
6536ee4f37f7
update the documentation
Aurelien Campeas <aurelien.campeas@logilab.fr>
parents:
2476
diff
changeset
|
13 |
* `format_time(time)` returns a string for a date time according to |
2476
1294a6bdf3bf
application -> instance where it makes sense
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents:
2172
diff
changeset
|
14 |
instance's configuration |
1714
a721966779be
new book layout, do not compile yet
sylvain.thenault@logilab.fr
parents:
diff
changeset
|
15 |
|
a721966779be
new book layout, do not compile yet
sylvain.thenault@logilab.fr
parents:
diff
changeset
|
16 |
:And more...: |
a721966779be
new book layout, do not compile yet
sylvain.thenault@logilab.fr
parents:
diff
changeset
|
17 |
|
a721966779be
new book layout, do not compile yet
sylvain.thenault@logilab.fr
parents:
diff
changeset
|
18 |
* `tal_render(template, variables)`, renders a precompiled page template with |
a721966779be
new book layout, do not compile yet
sylvain.thenault@logilab.fr
parents:
diff
changeset
|
19 |
variables in the given dictionary as context |
5149
a6bcb3c264fe
temporary move
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents:
5147
diff
changeset
|
20 |
|
a6bcb3c264fe
temporary move
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents:
5147
diff
changeset
|
21 |
|
a6bcb3c264fe
temporary move
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents:
5147
diff
changeset
|
22 |
Result set methods: |
a6bcb3c264fe
temporary move
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents:
5147
diff
changeset
|
23 |
|
a6bcb3c264fe
temporary move
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents:
5147
diff
changeset
|
24 |
* `get_entity(row, col)`, returns the entity corresponding to the data position |
a6bcb3c264fe
temporary move
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents:
5147
diff
changeset
|
25 |
in the *result set* |
a6bcb3c264fe
temporary move
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents:
5147
diff
changeset
|
26 |
|
a6bcb3c264fe
temporary move
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents:
5147
diff
changeset
|
27 |
* `complete_entity(row, col, skip_bytes=True)`, is equivalent to `get_entity` but |
a6bcb3c264fe
temporary move
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents:
5147
diff
changeset
|
28 |
also call the method `complete()` on the entity before returning it |
a6bcb3c264fe
temporary move
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents:
5147
diff
changeset
|
29 |
|
a6bcb3c264fe
temporary move
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents:
5147
diff
changeset
|
30 |