[UPD] README.rst

pull/2577/head
OCA-git-bot 2022-03-04 17:18:37 +00:00 committed by Simone Orsi
parent 0adb4459f8
commit 3ea0f29f20
2 changed files with 31 additions and 11 deletions

View File

@ -40,6 +40,9 @@ Provide helpers to authorize RPC calls.
Usage Usage
===== =====
Via code
~~~~~~~~
Decorate an Odoo model class like this:: Decorate an Odoo model class like this::
from odoo.addons.rpc_helper.decorator import disable_rpc from odoo.addons.rpc_helper.decorator import disable_rpc
@ -56,6 +59,12 @@ To selectively disable only some methods::
class AverageModel(models.Model): class AverageModel(models.Model):
_inherit = "avg.model" _inherit = "avg.model"
Via `ir.model` configuration
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
See "Configuration" section.
Bug Tracker Bug Tracker
=========== ===========

View File

@ -378,18 +378,24 @@ Only for development or testing purpose, do not use in production.
<p><strong>Table of contents</strong></p> <p><strong>Table of contents</strong></p>
<div class="contents local topic" id="contents"> <div class="contents local topic" id="contents">
<ul class="simple"> <ul class="simple">
<li><a class="reference internal" href="#usage" id="id1">Usage</a></li> <li><a class="reference internal" href="#usage" id="id1">Usage</a><ul>
<li><a class="reference internal" href="#bug-tracker" id="id2">Bug Tracker</a></li> <li><a class="reference internal" href="#via-code" id="id2">Via code</a></li>
<li><a class="reference internal" href="#credits" id="id3">Credits</a><ul> <li><a class="reference internal" href="#via-ir-model-configuration" id="id3">Via <cite>ir.model</cite> configuration</a></li>
<li><a class="reference internal" href="#authors" id="id4">Authors</a></li> </ul>
<li><a class="reference internal" href="#contributors" id="id5">Contributors</a></li> </li>
<li><a class="reference internal" href="#maintainers" id="id6">Maintainers</a></li> <li><a class="reference internal" href="#bug-tracker" id="id4">Bug Tracker</a></li>
<li><a class="reference internal" href="#credits" id="id5">Credits</a><ul>
<li><a class="reference internal" href="#authors" id="id6">Authors</a></li>
<li><a class="reference internal" href="#contributors" id="id7">Contributors</a></li>
<li><a class="reference internal" href="#maintainers" id="id8">Maintainers</a></li>
</ul> </ul>
</li> </li>
</ul> </ul>
</div> </div>
<div class="section" id="usage"> <div class="section" id="usage">
<h1><a class="toc-backref" href="#id1">Usage</a></h1> <h1><a class="toc-backref" href="#id1">Usage</a></h1>
<div class="section" id="via-code">
<h2><a class="toc-backref" href="#id2">Via code</a></h2>
<p>Decorate an Odoo model class like this:</p> <p>Decorate an Odoo model class like this:</p>
<pre class="literal-block"> <pre class="literal-block">
from odoo.addons.rpc_helper.decorator import disable_rpc from odoo.addons.rpc_helper.decorator import disable_rpc
@ -406,8 +412,13 @@ class AverageModel(models.Model):
_inherit = &quot;avg.model&quot; _inherit = &quot;avg.model&quot;
</pre> </pre>
</div> </div>
<div class="section" id="via-ir-model-configuration">
<h2><a class="toc-backref" href="#id3">Via <cite>ir.model</cite> configuration</a></h2>
<p>See “Configuration” section.</p>
</div>
</div>
<div class="section" id="bug-tracker"> <div class="section" id="bug-tracker">
<h1><a class="toc-backref" href="#id2">Bug Tracker</a></h1> <h1><a class="toc-backref" href="#id4">Bug Tracker</a></h1>
<p>Bugs are tracked on <a class="reference external" href="https://github.com/OCA/server-tools/issues">GitHub Issues</a>. <p>Bugs are tracked on <a class="reference external" href="https://github.com/OCA/server-tools/issues">GitHub Issues</a>.
In case of trouble, please check there if your issue has already been reported. In case of trouble, please check there if your issue has already been reported.
If you spotted it first, help us smashing it by providing a detailed and welcomed If you spotted it first, help us smashing it by providing a detailed and welcomed
@ -415,21 +426,21 @@ If you spotted it first, help us smashing it by providing a detailed and welcome
<p>Do not contact contributors directly about support or help with technical issues.</p> <p>Do not contact contributors directly about support or help with technical issues.</p>
</div> </div>
<div class="section" id="credits"> <div class="section" id="credits">
<h1><a class="toc-backref" href="#id3">Credits</a></h1> <h1><a class="toc-backref" href="#id5">Credits</a></h1>
<div class="section" id="authors"> <div class="section" id="authors">
<h2><a class="toc-backref" href="#id4">Authors</a></h2> <h2><a class="toc-backref" href="#id6">Authors</a></h2>
<ul class="simple"> <ul class="simple">
<li>Camptocamp</li> <li>Camptocamp</li>
</ul> </ul>
</div> </div>
<div class="section" id="contributors"> <div class="section" id="contributors">
<h2><a class="toc-backref" href="#id5">Contributors</a></h2> <h2><a class="toc-backref" href="#id7">Contributors</a></h2>
<ul class="simple"> <ul class="simple">
<li>Simone Orsi &lt;<a class="reference external" href="mailto:simone.orsi&#64;camptocamp.com">simone.orsi&#64;camptocamp.com</a>&gt;</li> <li>Simone Orsi &lt;<a class="reference external" href="mailto:simone.orsi&#64;camptocamp.com">simone.orsi&#64;camptocamp.com</a>&gt;</li>
</ul> </ul>
</div> </div>
<div class="section" id="maintainers"> <div class="section" id="maintainers">
<h2><a class="toc-backref" href="#id6">Maintainers</a></h2> <h2><a class="toc-backref" href="#id8">Maintainers</a></h2>
<p>This module is maintained by the OCA.</p> <p>This module is maintained by the OCA.</p>
<a class="reference external image-reference" href="https://odoo-community.org"><img alt="Odoo Community Association" src="https://odoo-community.org/logo.png" /></a> <a class="reference external image-reference" href="https://odoo-community.org"><img alt="Odoo Community Association" src="https://odoo-community.org/logo.png" /></a>
<p>OCA, or the Odoo Community Association, is a nonprofit organization whose <p>OCA, or the Odoo Community Association, is a nonprofit organization whose