Converting Search Suggetions to a Context. Search estimates is removed and suggestions is used instead.

This commit is contained in:
Roland 2023-11-22 12:19:49 -07:00
parent 57262442bd
commit bbfe76890b
No known key found for this signature in database
GPG key ID: 9D6DBD3ACF11AB93
13 changed files with 101 additions and 208 deletions

View file

@ -1003,22 +1003,6 @@ export async function fetchDecoded(vinNumber) {
}
}
export async function searchEstimate(search_str, tagNames) {
const body = {search_str: search_str, tag_names: tagNames};
const response = await apiPost(`${API_URI}/search_estimate`, body);
if (response.status === 200) {
const content = await response.json();
const zims = content['zims'];
let zimSum = 0;
zims.map(i => zimSum += i['estimate']);
return {
file_groups: content['file_groups'],
zims: zims,
zimSum: zimSum,
}
}
}
export async function searchSuggestions(search_str) {
const body = {search_str: search_str};
const response = await apiPost(`${API_URI}/search_suggestions`, body);