Skip to content
This repository was archived by the owner on Mar 3, 2025. It is now read-only.

Commit d46e78b

Browse files
committed
Correction de la recherche phonétique avec la lettre H
1 parent 891ccb3 commit d46e78b

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

noethysweb/individus/views/recherche_avancee.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,8 @@ def post(self, request, **kwargs):
5656
# Recherche textuelle
5757
if form.cleaned_data["type_recherche"] == "PHONETIQUE":
5858
if jellyfish.soundex(valeur_recherche) == jellyfish.soundex(valeur_individu):
59+
if valeur_recherche.startswith("H"): valeur_recherche = valeur_recherche[1:]
60+
if valeur_individu.startswith("H"): valeur_individu = valeur_individu[1:]
5961
score += 1 + jellyfish.jaro_distance(valeur_recherche.lower(), valeur_individu.lower())
6062

6163
# Recherche phonétique

0 commit comments

Comments
 (0)