Code
Explorer
You are a developer and looking for Shopware projects?
Apply Now!
addToleranceCondition example
return
null;
}
$tables
=
$this
->
getSearchTables
(
)
;
if
(
empty
(
$tables
)
)
{
return
null;
}
$query
=
$this
->
buildQueryFromKeywords
(
$keywords
,
$tables
)
;
$this
->
addToleranceCondition
(
$query
)
;
$query
->
select
(
[
'a.id as product_id',
'(' .
$this
->
getRelevanceSelection
(
)
. ') as ranking',
]
)
;
$enableAndSearchLogic
=
$this
->config->
get
(
'enableAndSearchLogic', false
)
;
if
(
$enableAndSearchLogic
)
{
$this
->
addAndSearchLogic
(
$query
,
$term
)
;
}