Skip to content

Commit

Permalink
sort by analysis
Browse files Browse the repository at this point in the history
Signed-off-by: TalyaNeima <[email protected]>
Signed-off-by: TalyaNaima <[email protected]>
  • Loading branch information
TalyaNaima authored and TalyaNaima committed Oct 13, 2024
1 parent 268c098 commit 41652e6
Showing 1 changed file with 7 additions and 13 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -338,7 +338,7 @@ export const ApplicationsTable: React.FC = () => {
sort: "sessionStorage",
},
isLoading: isFetchingApplications,
sortableColumns: ["name", "businessService", "tags", "effort"],
sortableColumns: ["name", "businessService", "tags", "effort","analysis"],
initialSort: { columnKey: "name", direction: "asc" },
initialColumns: {
name: { isIdentity: true },
Expand All @@ -348,6 +348,7 @@ export const ApplicationsTable: React.FC = () => {
businessService: app.businessService?.name || "",
tags: app.tags?.length || 0,
effort: app.effort || 0,
analysis: app.tasks.currentAnalyzer?.state || 0
}),
filterCategories: [
{
Expand Down Expand Up @@ -510,18 +511,11 @@ export const ApplicationsTable: React.FC = () => {
t("actions.filterBy", {
what: t("terms.analysis").toLowerCase(),
}) + "...",

// taskStateToAnalyze.map(state,icon)=>{
// value:

// } forEach.toString()}
// ApplicationAnalysisStatus.toString()
// Object.entries(Analy)
selectOptions: Array.from(taskStateToAnalyze).map(([taskState, displayStatus]) => ({
value: taskState, // The task state will be the value
label: t(`${displayStatus}`) // The display status translated using t()
})),

selectOptions: Array.from(taskStateToAnalyze).map(([taskState, displayStatus]) => ({
value: taskState, // The task state will be the value
label: t(`${displayStatus}`) // The display status translated using t()
})),

getItemValue: (item) => item?.tasks.currentAnalyzer?.state ||
"No task"
},
Expand Down

0 comments on commit 41652e6

Please sign in to comment.