[freeside-commits] freeside/FS/FS cust_main.pm,1.271.2.2,1.271.2.3
Jeff Finucane,420,,
jeff at wavetail.420.am
Tue Mar 20 13:22:00 PDT 2007
Update of /home/cvs/cvsroot/freeside/FS/FS
In directory wavetail:/tmp/cvs-serv16376/FS/FS
Modified Files:
Tag: FREESIDE_1_7_BRANCH
cust_main.pm
Log Message:
ticket 1418, a tool for customer note importation (backport)
Index: cust_main.pm
===================================================================
RCS file: /home/cvs/cvsroot/freeside/FS/FS/cust_main.pm,v
retrieving revision 1.271.2.2
retrieving revision 1.271.2.3
diff -u -d -r1.271.2.2 -r1.271.2.3
--- cust_main.pm 7 Mar 2007 19:49:15 -0000 1.271.2.2
+++ cust_main.pm 20 Mar 2007 20:21:57 -0000 1.271.2.3
@@ -4115,7 +4115,8 @@
Accepts the following options: I<search>, the string to search for. The string
will be searched for as a customer number, phone number, name or company name,
as an exact, or, in some cases, a substring or fuzzy match (see the source code
-for the exact heuristics used).
+for the exact heuristics used); I<no_fuzzy_on_exact>, causes smart_search to
+skip fuzzy matching when an exact match is found.
Any additional options are treated as an additional qualifier on the search
(i.e. I<agentnum>).
@@ -4132,6 +4133,7 @@
my @cust_main = ();
+ my $skup_fuzzy = delete $options{'no_fuzzy_on_exact'};
my $search = delete $options{'search'};
( my $alphanum_search = $search ) =~ s/\W//g;
@@ -4269,7 +4271,7 @@
#always do substring & fuzzy,
#getting complains searches are not returning enough
- #unless ( @cust_main ) { #no exact match, trying substring/fuzzy
+ unless ( @cust_main && $skip_fuzzy ) { #no exact match, trying substring/fuzzy
#still some false laziness w/ search/cust_main.cgi
@@ -4330,7 +4332,7 @@
FS::cust_main->fuzzy_search( { $field => $value }, @fuzopts );
}
- #}
+ }
#eliminate duplicates
my %saw = ();
More information about the freeside-commits
mailing list