Closed maimai-swap closed 7 years ago
What branch of this plugin are you using?
Thank you for your reply! I use this. composer.lock
"name": "cakephp/elastic-search",
"version": "0.3.4",
"source": {
"type": "git",
"url": "https://github.com/cakephp/elastic-search.git",
"reference": "e96022cefdfda37701dcd2d49e8326b27aecb00b"
},
I read the source of \Cake\ElasticSearch\Query::compileQuery.
I wished good I could set minscore like this..
/**
* Compile the Elasticsearch query.
*
* @return string The Elasticsearch query.
*/
public function compileQuery()
{
if($this->_options["min_score"]) {
$this->_elasticQuery->setMinScore("min_score",$this->_options["min_score"]);
}
// snip...
``
The ability to add min score was added in branch 1.0. I would suggest using that branch instead. The method name is called withMinScore()
I want to filter result by score.