Skip to content

Commit

Permalink
ref #285 done
Browse files Browse the repository at this point in the history
  • Loading branch information
CharlesGrimont committed Jan 6, 2025
1 parent 9cf23dd commit fedefcc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion _c8oProject/mobileSharedActions/searchForm.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
' page.c8o.callJsonObject("C8Oforms.APIV2_ExecuteView",{target: page.local["ddoc"] + "/search", dynamicParams: JSON.stringify({query: page["query"], tag: page.local.searchTags, subTag: page.local.searchSubTags})})
.then((response: any, parameters: any)=>{
page.local.count = response.res.docs.length;
var regex = new RegExp(page["query"].replace(/[.*+?^${}()|[\]\\]/g, ''\\$&''), ''g'');
var regex = new RegExp(page["query"].replace(/[.*+?^${}()|[\]\\]/g, ''\\$&''), ''gi'');
page["list"] = response.res.docs.map((x)=>{x.name = x.name.replace(regex, (match) => `<strong>${match}</strong>`); return x});
page.local.alreadyFinished = true;
page.local.spinner = false;
Expand Down

0 comments on commit fedefcc

Please sign in to comment.