kilbot / WooCommerce-POS

:bangbang: All development now at https://github.com/wcpos.
http://wcpos.com
GNU General Public License v3.0
353 stars 125 forks source link

Question: product search without diacritic #157

Open ToanVenota opened 7 years ago

ToanVenota commented 7 years ago

Hi, Is there a way to be able to search product without diacritics? For now if product if Banána, searching Banana will found nothing.

Thanks.

thomasmery commented 7 years ago

Hi,

as far as I know the behaviour you are used to with the WC Admin search won't work in the POS because the search is performed against the local (indexedDB) database that the plugin uses to speed up searches and it has limitations that prevent this.

Mysql can do this because of its support of characters set and collations:

https://dev.mysql.com/doc/refman/5.7/en/charset-general.html

kilbot commented 7 years ago

This could be achieved by combining a library such as node-diacritic to the JSON-query library.

It's not something I can look at right now for 0.5.0, but I will do some testing for 0.5.x.