Skip to content

armgit / plane

Public Imported from GitHub
0

πŸ”₯πŸ”₯πŸ”₯ Open-source Jira, Linear, Monday, and ClickUp alternative. Plane is a modern project management platform to manage tasks, sprints, docs, and triage.

fix: mutating the issues count in the archived issues header when we restore the issues (#5192)

guru_sainath8a05cd442c2d
diff --git a/web/app/[workspaceSlug]/(projects)/projects/(detail)/[projectId]/archives/header.tsx b/web/app/[workspaceSlug]/(projects)/projects/(detail)/[projectId]/archives/header.tsx
index 5f6db17a8a..0d68d7d615 100644
--- a/web/app/[workspaceSlug]/(projects)/projects/(detail)/[projectId]/archives/header.tsx
+++ b/web/app/[workspaceSlug]/(projects)/projects/(detail)/[projectId]/archives/header.tsx
@@ -26,17 +26,13 @@ export const ProjectArchivesHeader: FC<TProps> = observer((props: TProps) => {
const { workspaceSlug, projectId } = useParams();
// store hooks
const {
- issuesFilter: { issueFilters },
+ issues: { getGroupIssueCount },
} = useIssues(EIssuesStoreType.ARCHIVED);
const { currentProjectDetails, loader } = useProject();
// hooks
const { isMobile } = usePlatformOS();
- const issueCount = currentProjectDetails
- ? !issueFilters?.displayFilters?.sub_issue && currentProjectDetails.archived_sub_issues
- ? currentProjectDetails.archived_issues - currentProjectDetails.archived_sub_issues
- : currentProjectDetails.archived_issues
- : undefined;
+ const issueCount = getGroupIssueCount(undefined, undefined, false);
const activeTabBreadcrumbDetail =
PROJECT_ARCHIVES_BREADCRUMB_LIST[activeTab as keyof typeof PROJECT_ARCHIVES_BREADCRUMB_LIST];