diff options
| author | Chris McDonough <chrism@plope.com> | 2010-10-29 13:23:31 -0400 |
|---|---|---|
| committer | Chris McDonough <chrism@plope.com> | 2010-10-29 13:23:31 -0400 |
| commit | 197f0cb39d0a865476405dda21ad0d3e20ee0789 (patch) | |
| tree | 061f4595339022831dcd2c31275d0964eed77647 /docs/tutorials/wiki/authorization.rst | |
| parent | 66ecc57eb00063edfa01d66f8d6f4495d21d79b5 (diff) | |
| download | pyramid-197f0cb39d0a865476405dda21ad0d3e20ee0789.tar.gz pyramid-197f0cb39d0a865476405dda21ad0d3e20ee0789.tar.bz2 pyramid-197f0cb39d0a865476405dda21ad0d3e20ee0789.zip | |
bfg_view -> view_config
Diffstat (limited to 'docs/tutorials/wiki/authorization.rst')
| -rw-r--r-- | docs/tutorials/wiki/authorization.rst | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/docs/tutorials/wiki/authorization.rst b/docs/tutorials/wiki/authorization.rst index 0d135f5e2..189401a45 100644 --- a/docs/tutorials/wiki/authorization.rst +++ b/docs/tutorials/wiki/authorization.rst @@ -182,12 +182,12 @@ Our resulting ``models.py`` file will now look like so: :linenos: :language: python -Adding ``permission`` Declarations to our ``bfg_view`` Decorators ------------------------------------------------------------------ +Adding ``permission`` Declarations to our ``view_config`` Decorators +-------------------------------------------------------------------- To protect each of our views with a particular permission, we need to pass a ``permission`` argument to each of our -:class:`pyramid.view.bfg_view` decorators. To do so, within +:class:`pyramid.view.view_config` decorators. To do so, within ``views.py``: - We add ``permission='view'`` to the decorator attached to the @@ -220,10 +220,10 @@ pass a ``permission`` argument to each of our consults the ``GROUPS`` data structure. This means that the ``editor`` user can add pages. -- We add ``permission='edit'`` to the ``bfg_view`` decorator attached - to the ``edit_page`` view function. This makes the assertion that - only users who possess the effective ``edit`` permission at the time - of the request may invoke this view. We've granted the +- We add ``permission='edit'`` to the decorator attached to the + ``edit_page`` view function. This makes the assertion that only + users who possess the effective ``edit`` permission at the time of + the request may invoke this view. We've granted the ``group:editors`` principal the ``edit`` permission at the root model via its ACL, so only the a user whom is a member of the group named ``group:editors`` will able to invoke the ``edit_page`` view. |
