Skip to content

Commit

Permalink
Merge pull request #1950 from jplag/report-viewer/search-name-id
Browse files Browse the repository at this point in the history
Use name when processing search bar input
  • Loading branch information
tsaglam authored Aug 29, 2024
2 parents 0a868f2 + 5a03f70 commit d808ecd
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion report-viewer/src/components/ComparisonTableFilter.vue
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ const searchStringValue = computed({
}
for (const submissionId of store().getSubmissionIds) {
const submissionParts = submissionId.toLowerCase().split(/ +/g)
const submissionParts = store().submissionDisplayName(submissionId).toLowerCase().split(/ +/g)
if (submissionParts.every((part) => searchParts.includes(part))) {
store().state.anonymous.delete(submissionId)
}
Expand Down
6 changes: 3 additions & 3 deletions report-viewer/src/components/ComparisonsTable.vue
Original file line number Diff line number Diff line change
Expand Up @@ -236,9 +236,9 @@ function getFilteredComparisons(comparisons: ComparisonListElement[]) {

return comparisons.filter((c) => {
// name search
const id1 = c.firstSubmissionId.toLowerCase()
const id2 = c.secondSubmissionId.toLowerCase()
if (searches.some((s) => id1.includes(s) || id2.includes(s))) {
const name1 = store().submissionDisplayName(c.firstSubmissionId).toLowerCase()
const name2 = store().submissionDisplayName(c.secondSubmissionId).toLowerCase()
if (searches.some((s) => name1.includes(s) || name2.includes(s))) {
return true
}

Expand Down

0 comments on commit d808ecd

Please sign in to comment.