mirror of https://github.com/OCA/web.git
[UPD] README.rst
parent
0cd9334e90
commit
3b93c26ec0
|
@ -28,6 +28,7 @@ Show images in tree views via tooltip
|
|||
This module defines a images and icons in tree view via Tooltip.
|
||||
Additionally, Default width with 30px.
|
||||
|
||||
.. image:: https://raw.githubusercontent.com/OCA/web/12.0/web_tree_image_tooltip/static/description/tree_view_image.png
|
||||
|
||||
**Table of contents**
|
||||
|
||||
|
@ -39,11 +40,25 @@ Configuration
|
|||
|
||||
Insert `widget='image'` in your field view definition in any image field
|
||||
|
||||
.. code:: xml
|
||||
|
||||
<field name="image_field" widget="image"/>
|
||||
|
||||
|
||||
If the model has different fields of the same image with different size
|
||||
(as ``product.product`` for instance with ``image``, ``image_medium``, ``image_small``),
|
||||
you can write the following code to reduce the load duration of the tree view.
|
||||
|
||||
.. code:: xml
|
||||
|
||||
<field name="image_small" widget="image" options="{'tooltip_image': 'image'}"/>
|
||||
|
||||
Usage
|
||||
=====
|
||||
|
||||
Mouse Hover in tree view image that time Tooltip effect.
|
||||
|
||||
.. image:: https://raw.githubusercontent.com/OCA/web/12.0/web_tree_image_tooltip/static/description/tree_view_image_tooltip.png
|
||||
|
||||
Bug Tracker
|
||||
===========
|
||||
|
@ -73,6 +88,8 @@ Contributors
|
|||
* Jay Vora <jay.vora@serpentcs.com>
|
||||
* Meet Dholakia <m.dholakia.serpentcs@gmail.com>
|
||||
* Nikul Chaudhary <nikul.chaudhary.serpentcs@gmail.com>
|
||||
* Sylvain LE GAL (https://www.twitter.com/legalsylvain)
|
||||
|
||||
|
||||
|
||||
Other credits
|
||||
|
|
|
@ -370,6 +370,7 @@ ul.auto-toc {
|
|||
<p><a class="reference external" href="https://odoo-community.org/page/development-status"><img alt="Beta" src="https://img.shields.io/badge/maturity-Beta-yellow.png" /></a> <a class="reference external" href="http://www.gnu.org/licenses/agpl-3.0-standalone.html"><img alt="License: AGPL-3" src="https://img.shields.io/badge/licence-AGPL--3-blue.png" /></a> <a class="reference external" href="https://github.com/OCA/web/tree/12.0/web_tree_image_tooltip"><img alt="OCA/web" src="https://img.shields.io/badge/github-OCA%2Fweb-lightgray.png?logo=github" /></a> <a class="reference external" href="https://translation.odoo-community.org/projects/web-12-0/web-12-0-web_tree_image_tooltip"><img alt="Translate me on Weblate" src="https://img.shields.io/badge/weblate-Translate%20me-F47D42.png" /></a> <a class="reference external" href="https://runbot.odoo-community.org/runbot/162/12.0"><img alt="Try me on Runbot" src="https://img.shields.io/badge/runbot-Try%20me-875A7B.png" /></a></p>
|
||||
<p>This module defines a images and icons in tree view via Tooltip.
|
||||
Additionally, Default width with 30px.</p>
|
||||
<img alt="https://raw.githubusercontent.com/OCA/web/12.0/web_tree_image_tooltip/static/description/tree_view_image.png" src="https://raw.githubusercontent.com/OCA/web/12.0/web_tree_image_tooltip/static/description/tree_view_image.png" />
|
||||
<p><strong>Table of contents</strong></p>
|
||||
<div class="contents local topic" id="contents">
|
||||
<ul class="simple">
|
||||
|
@ -388,10 +389,20 @@ Additionally, Default width with 30px.</p>
|
|||
<div class="section" id="configuration">
|
||||
<h1><a class="toc-backref" href="#id1">Configuration</a></h1>
|
||||
<p>Insert <cite>widget=’image’</cite> in your field view definition in any image field</p>
|
||||
<pre class="code xml literal-block">
|
||||
<span class="nt"><field</span> <span class="na">name=</span><span class="s">"image_field"</span> <span class="na">widget=</span><span class="s">"image"</span><span class="nt">/></span>
|
||||
</pre>
|
||||
<p>If the model has different fields of the same image with different size
|
||||
(as <tt class="docutils literal">product.product</tt> for instance with <tt class="docutils literal">image</tt>, <tt class="docutils literal">image_medium</tt>, <tt class="docutils literal">image_small</tt>),
|
||||
you can write the following code to reduce the load duration of the tree view.</p>
|
||||
<pre class="code xml literal-block">
|
||||
<span class="nt"><field</span> <span class="na">name=</span><span class="s">"image_small"</span> <span class="na">widget=</span><span class="s">"image"</span> <span class="na">options=</span><span class="s">"{'tooltip_image': 'image'}"</span><span class="nt">/></span>
|
||||
</pre>
|
||||
</div>
|
||||
<div class="section" id="usage">
|
||||
<h1><a class="toc-backref" href="#id2">Usage</a></h1>
|
||||
<p>Mouse Hover in tree view image that time Tooltip effect.</p>
|
||||
<img alt="https://raw.githubusercontent.com/OCA/web/12.0/web_tree_image_tooltip/static/description/tree_view_image_tooltip.png" src="https://raw.githubusercontent.com/OCA/web/12.0/web_tree_image_tooltip/static/description/tree_view_image_tooltip.png" />
|
||||
</div>
|
||||
<div class="section" id="bug-tracker">
|
||||
<h1><a class="toc-backref" href="#id3">Bug Tracker</a></h1>
|
||||
|
@ -419,6 +430,7 @@ If you spotted it first, help us smashing it by providing a detailed and welcome
|
|||
<li>Jay Vora <<a class="reference external" href="mailto:jay.vora@serpentcs.com">jay.vora@serpentcs.com</a>></li>
|
||||
<li>Meet Dholakia <<a class="reference external" href="mailto:m.dholakia.serpentcs@gmail.com">m.dholakia.serpentcs@gmail.com</a>></li>
|
||||
<li>Nikul Chaudhary <<a class="reference external" href="mailto:nikul.chaudhary.serpentcs@gmail.com">nikul.chaudhary.serpentcs@gmail.com</a>></li>
|
||||
<li>Sylvain LE GAL (<a class="reference external" href="https://www.twitter.com/legalsylvain">https://www.twitter.com/legalsylvain</a>)</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="section" id="other-credits">
|
||||
|
|
Loading…
Reference in New Issue