[MIG] base_search_fuzzy: Migration to 15.0
[ADD] Roadmap: Module no longer needed from v16pull/2310/head
parent
484ca4b7d7
commit
a7224f1f6e
|
@ -14,13 +14,13 @@ Fuzzy Search
|
||||||
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
|
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
|
||||||
:alt: License: AGPL-3
|
:alt: License: AGPL-3
|
||||||
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fserver--tools-lightgray.png?logo=github
|
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fserver--tools-lightgray.png?logo=github
|
||||||
:target: https://github.com/OCA/server-tools/tree/14.0/base_search_fuzzy
|
:target: https://github.com/OCA/server-tools/tree/15.0/base_search_fuzzy
|
||||||
:alt: OCA/server-tools
|
:alt: OCA/server-tools
|
||||||
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
|
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
|
||||||
:target: https://translation.odoo-community.org/projects/server-tools-14-0/server-tools-14-0-base_search_fuzzy
|
:target: https://translation.odoo-community.org/projects/server-tools-15-0/server-tools-15-0-base_search_fuzzy
|
||||||
:alt: Translate me on Weblate
|
:alt: Translate me on Weblate
|
||||||
.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png
|
.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png
|
||||||
:target: https://runbot.odoo-community.org/runbot/149/14.0
|
:target: https://runbot.odoo-community.org/runbot/149/15.0
|
||||||
:alt: Try me on Runbot
|
:alt: Try me on Runbot
|
||||||
|
|
||||||
|badge1| |badge2| |badge3| |badge4| |badge5|
|
|badge1| |badge2| |badge3| |badge4| |badge5|
|
||||||
|
@ -90,6 +90,7 @@ Known issues / Roadmap
|
||||||
|
|
||||||
* Modify the general search parts (e.g. in tree view or many2one fields)
|
* Modify the general search parts (e.g. in tree view or many2one fields)
|
||||||
* Add better `order by` handling
|
* Add better `order by` handling
|
||||||
|
* This module will not be necessary from version 16 (`[IMP] Better handling of indexes #83015 <https://github.com/odoo/odoo/pull/83015>`_)
|
||||||
|
|
||||||
Bug Tracker
|
Bug Tracker
|
||||||
===========
|
===========
|
||||||
|
@ -97,7 +98,7 @@ Bug Tracker
|
||||||
Bugs are tracked on `GitHub Issues <https://github.com/OCA/server-tools/issues>`_.
|
Bugs are tracked on `GitHub Issues <https://github.com/OCA/server-tools/issues>`_.
|
||||||
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
|
||||||
`feedback <https://github.com/OCA/server-tools/issues/new?body=module:%20base_search_fuzzy%0Aversion:%2014.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.
|
`feedback <https://github.com/OCA/server-tools/issues/new?body=module:%20base_search_fuzzy%0Aversion:%2015.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.
|
||||||
|
|
||||||
Do not contact contributors directly about support or help with technical issues.
|
Do not contact contributors directly about support or help with technical issues.
|
||||||
|
|
||||||
|
@ -137,6 +138,6 @@ OCA, or the Odoo Community Association, is a nonprofit organization whose
|
||||||
mission is to support the collaborative development of Odoo features and
|
mission is to support the collaborative development of Odoo features and
|
||||||
promote its widespread use.
|
promote its widespread use.
|
||||||
|
|
||||||
This module is part of the `OCA/server-tools <https://github.com/OCA/server-tools/tree/14.0/base_search_fuzzy>`_ project on GitHub.
|
This module is part of the `OCA/server-tools <https://github.com/OCA/server-tools/tree/15.0/base_search_fuzzy>`_ project on GitHub.
|
||||||
|
|
||||||
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
|
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
|
||||||
|
|
|
@ -5,7 +5,7 @@
|
||||||
"name": "Fuzzy Search",
|
"name": "Fuzzy Search",
|
||||||
"summary": "Fuzzy search with the PostgreSQL trigram extension",
|
"summary": "Fuzzy search with the PostgreSQL trigram extension",
|
||||||
"category": "Uncategorized",
|
"category": "Uncategorized",
|
||||||
"version": "14.0.1.0.1",
|
"version": "15.0.1.0.0",
|
||||||
"website": "https://github.com/OCA/server-tools",
|
"website": "https://github.com/OCA/server-tools",
|
||||||
"author": "bloopark systems GmbH & Co. KG, "
|
"author": "bloopark systems GmbH & Co. KG, "
|
||||||
"ForgeFlow, "
|
"ForgeFlow, "
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
#
|
#
|
||||||
msgid ""
|
msgid ""
|
||||||
msgstr ""
|
msgstr ""
|
||||||
"Project-Id-Version: Odoo Server 14.0\n"
|
"Project-Id-Version: Odoo Server 15.0\n"
|
||||||
"Report-Msgid-Bugs-To: \n"
|
"Report-Msgid-Bugs-To: \n"
|
||||||
"Last-Translator: \n"
|
"Last-Translator: \n"
|
||||||
"Language-Team: \n"
|
"Language-Team: \n"
|
||||||
|
|
|
@ -28,7 +28,6 @@ class TrgmIndex(models.Model):
|
||||||
)
|
)
|
||||||
|
|
||||||
index_name = fields.Char(
|
index_name = fields.Char(
|
||||||
string="Index Name",
|
|
||||||
readonly=True,
|
readonly=True,
|
||||||
help="The index name is automatically generated like "
|
help="The index name is automatically generated like "
|
||||||
"fieldname_indextype_idx. If the index already exists and the "
|
"fieldname_indextype_idx. If the index already exists and the "
|
||||||
|
@ -39,7 +38,6 @@ class TrgmIndex(models.Model):
|
||||||
|
|
||||||
index_type = fields.Selection(
|
index_type = fields.Selection(
|
||||||
selection=[("gin", "GIN"), ("gist", "GiST")],
|
selection=[("gin", "GIN"), ("gist", "GiST")],
|
||||||
string="Index Type",
|
|
||||||
default="gin",
|
default="gin",
|
||||||
required=True,
|
required=True,
|
||||||
ondelete={"gin": "set default", "gist": "set default"},
|
ondelete={"gin": "set default", "gist": "set default"},
|
||||||
|
|
|
@ -1,2 +1,3 @@
|
||||||
* Modify the general search parts (e.g. in tree view or many2one fields)
|
* Modify the general search parts (e.g. in tree view or many2one fields)
|
||||||
* Add better `order by` handling
|
* Add better `order by` handling
|
||||||
|
* This module will not be necessary from version 16 (`[IMP] Better handling of indexes #83015 <https://github.com/odoo/odoo/pull/83015>`_)
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
||||||
<head>
|
<head>
|
||||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||||
<meta name="generator" content="Docutils 0.15.1: http://docutils.sourceforge.net/" />
|
<meta name="generator" content="Docutils: http://docutils.sourceforge.net/" />
|
||||||
<title>Fuzzy Search</title>
|
<title>Fuzzy Search</title>
|
||||||
<style type="text/css">
|
<style type="text/css">
|
||||||
|
|
||||||
|
@ -367,7 +367,7 @@ ul.auto-toc {
|
||||||
!! This file is generated by oca-gen-addon-readme !!
|
!! This file is generated by oca-gen-addon-readme !!
|
||||||
!! changes will be overwritten. !!
|
!! changes will be overwritten. !!
|
||||||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
|
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
|
||||||
<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/server-tools/tree/14.0/base_search_fuzzy"><img alt="OCA/server-tools" src="https://img.shields.io/badge/github-OCA%2Fserver--tools-lightgray.png?logo=github" /></a> <a class="reference external" href="https://translation.odoo-community.org/projects/server-tools-14-0/server-tools-14-0-base_search_fuzzy"><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/149/14.0"><img alt="Try me on Runbot" src="https://img.shields.io/badge/runbot-Try%20me-875A7B.png" /></a></p>
|
<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/server-tools/tree/15.0/base_search_fuzzy"><img alt="OCA/server-tools" src="https://img.shields.io/badge/github-OCA%2Fserver--tools-lightgray.png?logo=github" /></a> <a class="reference external" href="https://translation.odoo-community.org/projects/server-tools-15-0/server-tools-15-0-base_search_fuzzy"><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/149/15.0"><img alt="Try me on Runbot" src="https://img.shields.io/badge/runbot-Try%20me-875A7B.png" /></a></p>
|
||||||
<p>This addon provides the ability to create GIN or GiST indexes of char and text
|
<p>This addon provides the ability to create GIN or GiST indexes of char and text
|
||||||
fields and also to use the search operator <cite>%</cite> in search domains. Currently
|
fields and also to use the search operator <cite>%</cite> in search domains. Currently
|
||||||
this module doesn’t change the backend search or anything else. It provides
|
this module doesn’t change the backend search or anything else. It provides
|
||||||
|
@ -444,6 +444,7 @@ the search box and select <strong>Search Display Name for: …</strong></li>
|
||||||
<ul class="simple">
|
<ul class="simple">
|
||||||
<li>Modify the general search parts (e.g. in tree view or many2one fields)</li>
|
<li>Modify the general search parts (e.g. in tree view or many2one fields)</li>
|
||||||
<li>Add better <cite>order by</cite> handling</li>
|
<li>Add better <cite>order by</cite> handling</li>
|
||||||
|
<li>This module will not be necessary from version 16 (<a class="reference external" href="https://github.com/odoo/odoo/pull/83015">[IMP] Better handling of indexes #83015</a>.)</li>
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="bug-tracker">
|
<div class="section" id="bug-tracker">
|
||||||
|
@ -451,7 +452,7 @@ the search box and select <strong>Search Display Name for: …</strong></li>
|
||||||
<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
|
||||||
<a class="reference external" href="https://github.com/OCA/server-tools/issues/new?body=module:%20base_search_fuzzy%0Aversion:%2014.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**">feedback</a>.</p>
|
<a class="reference external" href="https://github.com/OCA/server-tools/issues/new?body=module:%20base_search_fuzzy%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>
|
<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">
|
||||||
|
@ -484,7 +485,7 @@ If you spotted it first, help us smashing it by providing a detailed and welcome
|
||||||
<p>OCA, or the Odoo Community Association, is a nonprofit organization whose
|
<p>OCA, or the Odoo Community Association, is a nonprofit organization whose
|
||||||
mission is to support the collaborative development of Odoo features and
|
mission is to support the collaborative development of Odoo features and
|
||||||
promote its widespread use.</p>
|
promote its widespread use.</p>
|
||||||
<p>This module is part of the <a class="reference external" href="https://github.com/OCA/server-tools/tree/14.0/base_search_fuzzy">OCA/server-tools</a> project on GitHub.</p>
|
<p>This module is part of the <a class="reference external" href="https://github.com/OCA/server-tools/tree/15.0/base_search_fuzzy">OCA/server-tools</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>
|
<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>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -38,10 +38,8 @@ class QueryGenerationCase(TransactionCase):
|
||||||
|
|
||||||
def test_fuzzy_where_generation_translatable(self):
|
def test_fuzzy_where_generation_translatable(self):
|
||||||
"""Check the generation of the where clause for translatable fields."""
|
"""Check the generation of the where clause for translatable fields."""
|
||||||
ctx = {"lang": "de_DE"}
|
|
||||||
|
|
||||||
# create new query with fuzzy search operator
|
# create new query with fuzzy search operator
|
||||||
query = self.ResPartnerCategory.with_context(ctx)._where_calc(
|
query = self.ResPartnerCategory.with_context(lang="de_DE")._where_calc(
|
||||||
[("name", "%", "Goschaeftlic")], active_test=False
|
[("name", "%", "Goschaeftlic")], active_test=False
|
||||||
)
|
)
|
||||||
from_clause, where_clause, where_clause_params = query.get_sql()
|
from_clause, where_clause, where_clause_params = query.get_sql()
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
<field name="name">trgm.index.view.form</field>
|
<field name="name">trgm.index.view.form</field>
|
||||||
<field name="model">trgm.index</field>
|
<field name="model">trgm.index</field>
|
||||||
<field name="arch" type="xml">
|
<field name="arch" type="xml">
|
||||||
<form string="Trigram Index">
|
<form>
|
||||||
<sheet>
|
<sheet>
|
||||||
<group col="4">
|
<group col="4">
|
||||||
<field
|
<field
|
||||||
|
@ -22,7 +22,7 @@
|
||||||
<field name="name">trgm.index.view.tree</field>
|
<field name="name">trgm.index.view.tree</field>
|
||||||
<field name="model">trgm.index</field>
|
<field name="model">trgm.index</field>
|
||||||
<field name="arch" type="xml">
|
<field name="arch" type="xml">
|
||||||
<tree string="Trigram Index">
|
<tree>
|
||||||
<field name="field_id" />
|
<field name="field_id" />
|
||||||
<field name="index_name" />
|
<field name="index_name" />
|
||||||
<field name="index_type" />
|
<field name="index_type" />
|
||||||
|
|
Loading…
Reference in New Issue