Skip to content

Commit

Permalink
Make package status columns sortable (#1082)
Browse files Browse the repository at this point in the history
  • Loading branch information
leSamo authored Jul 13, 2023
1 parent 977f285 commit 83f93b4
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/PresentationalComponents/TableView/TableViewAssets.js
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ export const systemPackagesColumns = [
},
{
title: intl.formatMessage(messages.labelsColumnsStatus),
transforms: [cellWidth(10)],
transforms: [sortable, cellWidth(10)],
key: 'updatable'
},
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@ exports[`SystemPackages.js Should match the snapshots 1`] = `
"title": "Status",
"transforms": Array [
[Function],
[Function],
],
},
Object {
Expand Down
5 changes: 2 additions & 3 deletions src/SmartComponents/Systems/SystemsListAssets.js
Original file line number Diff line number Diff line change
Expand Up @@ -105,11 +105,10 @@ export const packageSystemsColumns = [
}
},
{
key: 'upgradable',
key: 'updatable',
title: 'Status',
props: {
width: 20,
isStatic: true
width: 20
},
renderFunc: value => createUpgradableColumn(value)
}
Expand Down
1 change: 0 additions & 1 deletion src/Utilities/DataMappers.js
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,6 @@ export const createPackageSystemsRows = (rows, selectedRows = {}) => {
available_evra: row.updatable && row.available_evra || row.installed_evra,
disableSelection: !row.updatable,
updatable: row.updatable,
upgradable: row.updatable,
selected: selectedRows[row.id] !== undefined,
tags: row.tags
};
Expand Down

0 comments on commit 83f93b4

Please sign in to comment.