Search 1.9 billion lines of Odoo code on GitHub

website_sale_product_sort

Author: Tecnativa, Odoo Community Association (OCA)
License: AGPL-3
Branch: 15.0
Repository: brain-tec/e-commerce
Dependencies: website_sale
Languages: HTML (377, 51.8%), PO File (161, 22.1%), Python (63, 8.7%), XML (46, 6.3%), and reStructuredText (81, 11.1%)
Other branches: 12.0, 12.0-ocabot-merge-pr-360-by-pedrobaeza-bump-nobump, 12.0-ocabot-merge-pr-373-by-pedrobaeza-bump-nobump, 12.0-ocabot-merge-pr-449-by-dreispt-bump-nobump, 13.0, 13.0-ocabot-merge-pr-435-by-dreispt-bump-nobump, 13.0-ocabot-merge-pr-483-by-dreispt-bump-minor, 13.0-ocabot-merge-pr-499-by-pedrobaeza-bump-nobump, 13.0-ocabot-merge-pr-505-by-pedrobaeza-bump-nobump, 13.0-ocabot-merge-pr-508-by-pedrobaeza-bump-nobump, 13.0-ocabot-merge-pr-524-by-pedrobaeza-bump-nobump, and 13.0-ocabot-merge-pr-617-by-pedrobaeza-bump-minor
Other repositories: AITIC/e-commerce, CB-Gran-Canaria/e-commerce, Change2improve/e-commerce, Comunitea/e-commerce, ERPLibre/e-commerce, ForgeFlow/e-commerce, Gabinete-Digital/e-commerce, Ingeos/e-commerce, LeaMartinek/e-commerce, LevelPrime/e-commerce, NeatNerdPrime/e-commerce, NextERP-Romania/e-commerce, Nitrokey/odoo-e-commerce, OCA-MUK/e-commerce, OCA/e-commerce, Spearhead-Odoo/e-commerce, Strusovsky/e-commerce, TDu/e-commerce, Tecnativa/e-commerce, Vauxoo/e-commerce, acsone/e-commerce, adhoc-dev/e-commerce, agrista/odoo-e-commerce, akretion/e-commerce, anhvu-sg/e-commerce, bacgroup/e-commerce, camptocamp/e-commerce, celm1990/e-commerce, coopiteasy/e-commerce, eLBati/e-commerce, eezee-it/web, fallewi/e-commerce, fcayre/e-commerce, gurneyalex/e-commerce, jctrey/e-commerce, jromeroarg/e-commerce, killvis/e-commerce, lideritjnma/e-commerce, mamcode/e-commerce, moltisinc/e-commerce, myceliandre/e-commerce, noorealam96/e-commerce, samsagaz/e-commerce, sendalpegat/e-commerce, tarteo/e-commerce, wahello/e-commerce, wtaferner/e-commerce, and zeroheure/e-commerce

<h1 class="title">Website Sale Product Sort</h1> <p><a class="reference external" href="https://odoo-community.org/page/development-status"><img alt="Production/Stable" src="https://img.shields.io/badge/maturity-Production%2FStable-green.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/e-commerce/tree/15.0/website_sale_product_sort"><img alt="OCA/e-commerce" src="https://img.shields.io/badge/github-OCA%2Fe--commerce-lightgray.png?logo=github" /></a> <a class="reference external" href="https://translation.odoo-community.org/projects/e-commerce-15-0/e-commerce-15-0-website_sale_product_sort"><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/113/15.0"><img alt="Try me on Runbot" src="https://img.shields.io/badge/runbot-Try%20me-875A7B.png" /></a></p> <p>This module allows to set a default sorting criteria for the e-commerce product list.</p> <p>It provides the standard criterias, but allows to extend the options via third modules.</p> <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></li> <li><a class="reference internal" href="#usage" id="id2">Usage</a></li> <li><a class="reference internal" href="#known-issues-roadmap" id="id3">Known issues / Roadmap</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> </li> </ul> </div> <a name="configuration"></a> <h2><a class="toc-backref" href="#id1">Configuration</a></h2> <p>To configure this module, you need to:</p> <ol class="arabic simple"> <li>Go to <em>Website &gt; Configuration &gt; Settings</em></li> <li>Select the website you want to configure.</li> <li>In the <em>Product</em> section there's a <em>Sort Criteria</em> option that you can set as the default one for the website selected.</li> </ol> <p>To extend the module you can override the method providing sorting options like this:</p> <blockquote> <pre> <code lang="python">&#64;api.model def _get_product_sort_criterias(self): res = super()._get_product_sort_criterias() return res.append((&quot;default_code asc&quot;, _(&quot;Reference - A to Z&quot;)))</code> </pre> </blockquote> <a name="usage"></a> <h2><a class="toc-backref" href="#id2">Usage</a></h2> <p>After you've configured the default website settings:</p> <ol class="arabic simple"> <li>Go to the configured website shop url.</li> <li>The products will be sorted by default by the chosen option.</li> </ol> <a name="known-issues-roadmap"></a> <h2><a class="toc-backref" href="#id3">Known issues / Roadmap</a></h2> <ul class="simple"> <li>Could be nice to have a related model to configure the sorting options without the need of third modules.</li> </ul> <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/OCA/e-commerce/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/OCA/e-commerce/issues/new?body=module:%20website_sale_product_sort%0Aversion:%2015.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>Tecnativa</li> </ul> <a name="contributors"></a> <h3><a class="toc-backref" href="#id7">Contributors</a></h3> <ul> <li><p class="first"><a class="reference external" href="https://www.tecnativa.com">Tecnativa</a>:</p> <blockquote> <ul class="simple"> <li>David Vidal</li> <li>Carlos Roca</li> </ul> </blockquote> </li> </ul> <a name="maintainers"></a> <h3><a class="toc-backref" href="#id8">Maintainers</a></h3> <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> <p>OCA, or the Odoo Community Association, is a nonprofit organization whose mission is to support the collaborative development of Odoo features and promote its widespread use.</p> <p>This module is part of the <a class="reference external" href="https://github.com/OCA/e-commerce/tree/15.0/website_sale_product_sort">OCA/e-commerce</a> project on GitHub.</p> <p>You are welcome to contribute. To learn how please visit <a class="reference external" href="https://odoo-community.org/page/Contribute">https://odoo-community.org/page/Contribute</a>.</p>