mirror of
https://github.com/nasa/openmct.git
synced 2025-02-22 18:12:57 +00:00
[Search] Moved hard coding
Moved where the search type is prepended to the search term, to allow future changes to it.
This commit is contained in:
parent
7c627fae8f
commit
27c7410318
@ -158,11 +158,13 @@ define(
|
||||
// '*sine* OR *telemetry*'
|
||||
searchTerm = '*' + searchTerm + '*';
|
||||
}
|
||||
// Assume that the search term is for the name by default
|
||||
searchTerm = "name:" + searchTerm;
|
||||
|
||||
// Get the data...
|
||||
return $http({
|
||||
method: "GET",
|
||||
url: ROOT + "/_search/?q=name:" + searchTerm +
|
||||
url: ROOT + "/_search/?q=" + searchTerm +
|
||||
"&size=" + maxResults
|
||||
}).then(function (rawResults) {
|
||||
// ...then process the data
|
||||
|
Loading…
x
Reference in New Issue
Block a user