Update SearchController.cs
This commit is contained in:
parent
fe5d00264d
commit
43a59ee1a7
@ -45,7 +45,6 @@ public class SearchController : Controller {
|
|||||||
string sTitle = prod.Title.Replace(".", " ").Replace(",", " ").ToLower(),
|
string sTitle = prod.Title.Replace(".", " ").Replace(",", " ").ToLower(),
|
||||||
sCat = prod.Category.Replace(".", " ").Replace(",", " ").ToLower(),
|
sCat = prod.Category.Replace(".", " ").Replace(",", " ").ToLower(),
|
||||||
sDesc = prod.Description.Replace(".", " ").Replace(",", " ").ToLower();
|
sDesc = prod.Description.Replace(".", " ").Replace(",", " ").ToLower();
|
||||||
|
|
||||||
if (sTitle.StartsWith(query))
|
if (sTitle.StartsWith(query))
|
||||||
products.Add(prod);
|
products.Add(prod);
|
||||||
else if (sTitle.Contains(" " + query + " "))
|
else if (sTitle.Contains(" " + query + " "))
|
||||||
|
Loading…
Reference in New Issue
Block a user