Skip to content

Commit

Permalink
Fix Ordering by business critically in products list (#8693)
Browse files Browse the repository at this point in the history
* Fix checkbox disappear findings (windows resize)

* fix checkboxes disappear in all project

* fix 500 error when attempting to order tags

* fix flake8 issue

* Fix Bulk edit drop-down bug

* trivy parser Includes causeMetadata in the findings description

* Revert "trivy parser Includes causeMetadata in the findings description"

This reverts commit da493b9.

* Fix Ordering by business critically in products list

---------

Co-authored-by: Felix Hernandez <[email protected]>
  • Loading branch information
FelixHernandez and felixhernandez15 authored Sep 20, 2023
1 parent e170b82 commit 68eb8fc
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion dojo/templates/dojo/product.html
Original file line number Diff line number Diff line change
Expand Up @@ -342,7 +342,16 @@ <h3 class="has-filters">
{ "data": "product" },
{ "data": "tags" },
{ "data": "criticality" , render: function (data, type, row) {
return type === 'export' ? getDojoExportValueFromTag(data, 'i', 'data-content') : data;
const criticals = {
'Very High': 5,
'High': 4,
'Medium': 3,
'Low': 2,
'Very Low': 1,
'None': 0
};
return type === 'sort' ? criticals[getDojoExportValueFromTag(data, 'i', 'data-content')] :
type === 'export' ? getDojoExportValueFromTag(data, 'i', 'data-content') : data;
}},
{ "data": "metadata", render: function (data, type, row) {
return type === 'export' ? getDojoExportValueFromTag(data, 'i', 'data-content') : data;
Expand Down

0 comments on commit 68eb8fc

Please sign in to comment.