Closed noyainrain closed 9 years ago
Draft:
class Editable:
"""
.. describe:: authors
:ref:`User` s who edited the object.
--
The :meth:`Object.json` method of editable objects accepts an additional argument
*include_users*. If it is ``True``, :class:`User` s are included as JSON objects (instead of
IDs).
"""
def do_edit():
"""
Called by :meth:`edit`, which takes care of basic permission checking, managing *authors*
and storing the updated object in the database.
"""
def json(self, include_users=False):
"""
Subclass API: Return a JSON object representation of the Editable part of the object.
"""
Implemented in ff1511e795d432a0504f105874bff5425215a5e6 .
Introduce
Editable.authors
which tracks users who edited (or created) an object.Depends on #4 .