Skip to content

Commit c89f4a6

Browse files
committed
Realign documentation
1 parent 686c2e4 commit c89f4a6

File tree

2 files changed

+13
-12
lines changed

2 files changed

+13
-12
lines changed

docs/api.rst

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,10 @@ for database management. Use :func:`dir` function to introspect them.
8787

8888
Expose the ``/web/webclient`` :class:`WebAPI`.
8989

90+
.. autoclass:: WebAPI
91+
:members:
92+
:undoc-members:
93+
9094

9195
Odoo RPC Services
9296
~~~~~~~~~~~~~~~~~
@@ -142,10 +146,6 @@ Please refer to `the Odoo documentation`_ for more details.
142146

143147
Removed in OpenERP 7.
144148

145-
.. autoclass:: WebAPI
146-
:members:
147-
:undoc-members:
148-
149149
.. autoclass:: Service
150150
:members:
151151
:undoc-members:
@@ -158,7 +158,7 @@ Environment
158158
-----------
159159

160160
.. autoclass:: Env
161-
:members: lang, execute, access, models, ref, __getitem__, odoo_env, registry
161+
:members: lang, access, models, ref, __getitem__, odoo_env, registry
162162
:undoc-members:
163163

164164
.. attribute:: db_name
@@ -219,7 +219,7 @@ Please refer to `the Odoo documentation`_ for details.
219219

220220
.. attribute:: Env._web(obj, method, *params, **kwargs)
221221

222-
Expose the root of the ``/web`` API.
222+
Expose the ``/web`` API and its endpoints.
223223

224224
.. method:: Env.exec_workflow(obj, signal, obj_id)
225225

odooly.py

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -517,11 +517,11 @@ def __new__(cls, client, db_name=()):
517517
return env
518518

519519
def __contains__(self, name):
520-
"""Test wether the given model exists."""
520+
"""Test wether this model exists."""
521521
return name in self._model_names or name in self.models(name)
522522

523523
def __getitem__(self, name):
524-
"""Return the given :class:`Model`."""
524+
"""Return the :class:`Model` for the given ``name``."""
525525
return self._get(name)
526526

527527
def __iter__(self):
@@ -741,11 +741,12 @@ def _cache_set(self, key, value, db_name=None):
741741
return value
742742

743743
def execute(self, obj, method, *params, **kwargs):
744-
"""Wrapper around ``object.execute_kw`` RPC method.
744+
"""Wrapper around ``/web/dataset/call_kw`` Web endpoint,
745+
or ``object.execute_kw`` RPC method.
745746
746-
Argument `method` is the name of an ``osv.osv`` method or
747-
a method available on this `obj`.
748-
Method `params` are allowed. If needed, keyword
747+
Argument `method` is the name of a standard ``Model`` method
748+
or a specific method available on this `obj`.
749+
Method `params` are accepted. If needed, keyword
749750
arguments are collected in `kwargs`.
750751
"""
751752
assert self.uid, 'Not connected'

0 commit comments

Comments
 (0)