diff options
| author | cguardia <carlos.delaguardia@gmail.com> | 2011-04-25 00:37:33 -0500 |
|---|---|---|
| committer | cguardia <carlos.delaguardia@gmail.com> | 2011-04-25 00:37:33 -0500 |
| commit | b61680ad87abcb524ae3fe846cd591c6ec1d54ef (patch) | |
| tree | e2fcd960d9119efde4a1b7eecec3880f98397d2f /docs/tutorials/wiki2/definingmodels.rst | |
| parent | 1b395e6d43b9450ea652d9addb675936b507ea52 (diff) | |
| parent | bb825910b3b68b4b167572fd5252cc99be88e17e (diff) | |
| download | pyramid-b61680ad87abcb524ae3fe846cd591c6ec1d54ef.tar.gz pyramid-b61680ad87abcb524ae3fe846cd591c6ec1d54ef.tar.bz2 pyramid-b61680ad87abcb524ae3fe846cd591c6ec1d54ef.zip | |
Merge branch 'master' of https://github.com/Pylons/pyramid
Diffstat (limited to 'docs/tutorials/wiki2/definingmodels.rst')
| -rw-r--r-- | docs/tutorials/wiki2/definingmodels.rst | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/docs/tutorials/wiki2/definingmodels.rst b/docs/tutorials/wiki2/definingmodels.rst index 1661753c1..e5d283125 100644 --- a/docs/tutorials/wiki2/definingmodels.rst +++ b/docs/tutorials/wiki2/definingmodels.rst @@ -26,6 +26,14 @@ The first thing we want to do is remove the stock ``MyModel`` class from the generated ``models.py`` file. The ``MyModel`` class is only a sample and we're not going to use it. +Next, we'll remove the :class:`sqlalchemy.Unicode` import and replace it +with :class:`sqlalchemy.Text`. + +.. literalinclude:: src/models/tutorial/models.py + :lines: 5 + :linenos: + :language: py + Then, we'll add a ``Page`` class. Because this is a SQLAlchemy application, this class should inherit from an instance of :class:`sqlalchemy.ext.declarative.declarative_base`. Declarative |
