Search 1.9 billion lines of Odoo code on GitHub

product_print_category_food_report

Author: GRAP
License: AGPL-3
Branch: 12.0
Repository: grap/grap-odoo-business
Dependencies: base, decimal_precision, product_food, product_label, product_origin, product_origin_l10n_fr_department, product_print_category, uom, and web
Languages: HTML (390, 20.0%), PO File (140, 7.2%), Python (185, 9.5%), Sass (483, 24.7%), XML (673, 34.4%), and reStructuredText (83, 4.2%)
Other repositories: quentinDupont/grap-odoo-incubator

<h1 class="title">Product print category food report</h1> <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/grap/grap-odoo-business/tree/12.0/product_print_category_food_report"><img alt="grap/grap-odoo-business" src="https://img.shields.io/badge/github-grap%2Fgrap--odoo--business-lightgray.png?logo=github" /></a></p> <p>This module extends product_print_category by adding nice reports food related. At the moment, we create five different pricetag reports.</p> <p>Specifications :</p> <ul class="simple"> <li>We add a <code>pricetag_type</code> which permits to assign a color for the pricetags.</li> <li>We can choose a second unity of measure in order to display the price with a more appropriate unity (for example for very expensive products)</li> <li>Thanks to product_food module, ingredients, allergens are displayed in bulk reports</li> <li>Thanks to product_label and product_origin, we also display labels and origin</li> </ul> <p>Here is what's look like the reports :</p> <ul class="simple"> <li>Normal pricetag &quot;classic format&quot; 76x31mm</li> </ul> <div class="figure"> <img alt="https://raw.githubusercontent.com/grap/grap-odoo-business/12.0/product_print_category_food_report/static/img/pricetag_normal.png" src="https://raw.githubusercontent.com/grap/grap-odoo-business/12.0/product_print_category_food_report/static/img/pricetag_normal.png" /> </div> <ul class="simple"> <li>Bulk pricetag long designed for Applimage bulk equipment 52x101mm</li> </ul> <div class="figure"> <img alt="https://raw.githubusercontent.com/grap/grap-odoo-business/12.0/product_print_category_food_report/static/img/pricetag_bulk_long.png" src="https://raw.githubusercontent.com/grap/grap-odoo-business/12.0/product_print_category_food_report/static/img/pricetag_bulk_long.png" /> </div> <ul class="simple"> <li>Bulk pricetag square 93x93mm</li> </ul> <div class="figure"> <img alt="https://raw.githubusercontent.com/grap/grap-odoo-business/12.0/product_print_category_food_report/static/img/pricetag_bulk_square.png" src="https://raw.githubusercontent.com/grap/grap-odoo-business/12.0/product_print_category_food_report/static/img/pricetag_bulk_square.png" /> </div> <ul class="simple"> <li>Square pricetag 40x36mm</li> </ul> <div class="figure"> <img alt="https://raw.githubusercontent.com/grap/grap-odoo-business/12.0/product_print_category_food_report/static/img/pricetag_square.png" src="https://raw.githubusercontent.com/grap/grap-odoo-business/12.0/product_print_category_food_report/static/img/pricetag_square.png" /> </div> <ul class="simple"> <li>Counter pricetag - 72*123mm</li> </ul> <div class="figure"> <img alt="https://raw.githubusercontent.com/grap/grap-odoo-business/12.0/product_print_category_food_report/static/img/pricetag_counter.png" src="https://raw.githubusercontent.com/grap/grap-odoo-business/12.0/product_print_category_food_report/static/img/pricetag_counter.png" /> </div> <p><strong>Table of contents</strong></p> <div class="contents local topic" id="contents"> <ul class="simple"> <li><a class="reference internal" href="#configuration" id="id1">Configuration</a><ul> <li><a class="reference internal" href="#barcodes" id="id2">Barcodes</a></li> <li><a class="reference internal" href="#for-your-css" id="id3">For your css</a></li> </ul> </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> </li> </ul> </div> <a name="configuration"></a> <h2><a class="toc-backref" href="#id1">Configuration</a></h2> <a name="barcodes"></a> <h3><a class="toc-backref" href="#id2">Barcodes</a></h3> <p>Report use barcode image handle <a class="reference external" href="https://www.odoo.com/documentation/12.0/reference/reports.html#barcodes">directly by Odoo</a> To make it wortk in your report :</p> <ol class="arabic simple"> <li>Update wkhtmltopdf to version 0.12.5</li> <li>Add new system parameter : <code>Key: web.base.url.freeze Value: True</code></li> <li>Change your report definition by using web_basic_layout <code>&lt;template&gt; &lt;t t-call=&quot;web.basic_layout&quot;&gt;your things&lt;/t&gt; &lt;/template&gt;</code></li> </ol> <a name="for-your-css"></a> <h3><a class="toc-backref" href="#id3">For your css</a></h3> <p>To use custom css in report, we can use inline css or externalize css file (even scss). For this purpose, add your css file in web.report_assets_common</p> <p><code>&lt;template id=&quot;id_css_for_my_report&quot; inherit_id=&quot;web.report_assets_common&quot;&gt; &lt;xpath expr=&quot;.&quot; position=&quot;inside&quot;&gt; &lt;link href=&quot;/product_print_category_food_report/static/css/my_css.scss&quot; rel=&quot;stylesheet&quot; type=&quot;text/scss&quot;/&gt; &lt;/xpath&gt; &lt;/template&gt;</code></p> <p>Beware, all css file will be shared, so you can't have the same css calling rules for two differents results. You can use scss nesting for that purpose.</p> <a name="bug-tracker"></a> <h2><a class="toc-backref" href="#id4">Bug Tracker</a></h2> <p>Bugs are tracked on <a class="reference external" href="https://github.com/grap/grap-odoo-business/issues">GitHub Issues</a>. 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 <a class="reference external" href="https://github.com/grap/grap-odoo-business/issues/new?body=module:%20product_print_category_food_report%0Aversion:%2012.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**">feedback</a>.</p> <p>Do not contact contributors directly about support or help with technical issues.</p> <a name="credits"></a> <h2><a class="toc-backref" href="#id5">Credits</a></h2> <a name="authors"></a> <h3><a class="toc-backref" href="#id6">Authors</a></h3> <ul class="simple"> <li>GRAP</li> </ul> <a name="contributors"></a> <h3><a class="toc-backref" href="#id7">Contributors</a></h3> <ul class="simple"> <li>Sylvain LE GAL &lt;<a class="reference external" href="https://twitter.com/legalsylvain">https://twitter.com/legalsylvain</a>&gt;</li> <li>Quentin DUPONT &lt;<a class="reference external" href="https://twitter.com/pondupont">https://twitter.com/pondupont</a>&gt;</li> </ul> <a name="maintainers"></a> <h3><a class="toc-backref" href="#id8">Maintainers</a></h3> <p>This module is part of the <a class="reference external" href="https://github.com/grap/grap-odoo-business/tree/12.0/product_print_category_food_report">grap/grap-odoo-business</a> project on GitHub.</p> <p>You are welcome to contribute.</p>