Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🐛 notifications close all together bug #2118

Open
wants to merge 4 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion client/public/locales/en/translation.json
Original file line number Diff line number Diff line change
Expand Up @@ -507,7 +507,8 @@
"success": {
"saveWhat": "{{type}} {{what}} was successfully saved.",
"save": "{{type}} was successfully saved.",
"applicationDeleted": "{{appIDCount}} application(s) successfully deleted.",
"applicationDeleted": "{{appName}} application(s) successfully deleted.",
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not a native speaker but I would suggest Application {{appName}} successfully deleted.

"applicationsDeleted": "{{appIDcount}} application(s) successfully deleted.",
"assessmentAndReviewCopied": "Success! Assessment and review copied to selected applications",
"assessmentCopied": "Success! Assessment copied to selected applications",
"assessmentDiscarded": "Success! Assessment discarded for {{application}}.",
Expand Down
3 changes: 2 additions & 1 deletion client/public/locales/es/translation.json
Original file line number Diff line number Diff line change
Expand Up @@ -309,7 +309,8 @@
"toastr": {
"success": {
"added": "Éxito! {{what}} fue creado como un {{type}}.",
"applicationDeleted": "{{appIDCount}} aplicacione(s) descheda.",
"applicationDeleted": "{{appName}} aplicacione descheda.",
rszwajko marked this conversation as resolved.
Show resolved Hide resolved
"applicationsDeleted": "{{appIDcount}} aplicacione(s) descheda.",
"assessmentAndReviewCopied": "Éxito! Evaluación y revisión copiada a las aplicaciones seleccionadas",
"assessmentCopied": "Éxito! Evaluación copiada a las aplicaciones seleccionadas",
"assessmentDiscarded": "Éxito! Evaluación de {{application}} desechada.",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -234,12 +234,20 @@ export const ApplicationsTable: React.FC = () => {
} = useDecoratedApplications(baseApplications, tasks);

const onDeleteApplicationSuccess = (appIDCount: number) => {
pushNotification({
title: t("toastr.success.applicationDeleted", {
appIDCount: appIDCount,
}),
variant: "success",
});
if (applicationsToDelete.length == 1)
pushNotification({
title: t("toastr.success.applicationDeleted", {
appName: applicationsToDelete[0].name,
}),
variant: "success",
});
else
pushNotification({
title: t("toastr.success.applicationsDeleted", {
appIdCount: appIDCount,
}),
variant: "success",
});
clearActiveItem();
setApplicationsToDelete([]);
};
Expand Down Expand Up @@ -345,6 +353,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,
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this change related to the fix? If no then please revert.

}),
filterCategories: [
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ export interface ApplicationAnalysisStatusProps {
state: TaskState;
}

const taskStateToAnalyze: Map<TaskState, IconedStatusPreset> = new Map([
export const taskStateToAnalyze: Map<TaskState, IconedStatusPreset> = new Map([
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this change related to the fix?

["not supported", "Canceled"],
["Canceled", "Canceled"],
["Created", "Scheduled"],
Expand Down
Loading