Skip to content

Commit

Permalink
Fix warning tooltip to show line breaks and not show dupe warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
eckermania committed Jul 8, 2024
1 parent b0474ff commit dcca059
Showing 1 changed file with 6 additions and 7 deletions.
13 changes: 6 additions & 7 deletions frontend/src/components/common/CustomTable.vue
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,9 @@
{{ getSdcStudentIssueIcon(props.item['sdcSchoolCollectionStudentStatusCode']) }}
</v-icon>
</template>
{{ getSdcStudentStatusHoverText(props.item['sdcSchoolCollectionStudentStatusCode'], props.item['sdcSchoolCollectionStudentValidationIssues']) }}
<div style="white-space: pre-line;">
{{ getSdcStudentStatusHoverText(props.item['sdcSchoolCollectionStudentStatusCode'], props.item['sdcSchoolCollectionStudentValidationIssues']) }}
</div>
</v-tooltip>
<div v-else>
<span v-if="column.key === 'studentPen'">
Expand Down Expand Up @@ -304,14 +306,11 @@ export default {
},
getSdcStudentStatusHoverText(status, codes) {
if (status === 'FUNDWARN' || status === 'INFOWARN') {
let hoverText = '';
let hoverTextSet = new Set();
codes.forEach((code, index) => {

Check failure on line 310 in frontend/src/components/common/CustomTable.vue

View workflow job for this annotation

GitHub Actions / test

'index' is defined but never used

Check failure on line 310 in frontend/src/components/common/CustomTable.vue

View workflow job for this annotation

GitHub Actions / test

'index' is defined but never used
if (index !== 0){
hoverText += '\n';
}
hoverText += sdcCollectionStore().validationIssueTypeCodesMap.get(code.validationIssueCode)?.message;
hoverTextSet.add(sdcCollectionStore().validationIssueTypeCodesMap.get(code.validationIssueCode)?.message);
})
return hoverText;
return Array.from(hoverTextSet).join("\n");
}
},
getAssignedPen(assignedPen) {
Expand Down

0 comments on commit dcca059

Please sign in to comment.