From 5a52cfe3d156dbbe14fc0c4ce4b14800adb4ad41 Mon Sep 17 00:00:00 2001 From: Manuel Rodriguez Date: Thu, 7 Dec 2023 13:54:14 -0800 Subject: [PATCH] Disposition/menu entry (#3639) * Added check status logic when updating acq and related entities | psp-7006 (#3602) * Added status checking to details, take, compensation and other acq file pages * Updated backend and updated tests * Fixed lint * Refactored solver to be simpler * Added tests * Pr comments * Added the sys-admin to edit acquisition fields * CI: Bump version to v4.0.0-67.24 * Updated placeholder display (#3620) * CI: Bump version to v4.0.0-67.25 * Added the disposition entry into the menu list --------- Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> --- .../layout/SideNavBar/SideNavbar.tsx | 7 +++ .../components/layout/SideNavBar/SideTray.tsx | 3 ++ .../__snapshots__/SideNavbar.test.tsx.snap | 45 +++++++++++++++++++ 3 files changed, 55 insertions(+) diff --git a/source/frontend/src/components/layout/SideNavBar/SideNavbar.tsx b/source/frontend/src/components/layout/SideNavBar/SideNavbar.tsx index 8836974577..0b0d198f7e 100644 --- a/source/frontend/src/components/layout/SideNavBar/SideNavbar.tsx +++ b/source/frontend/src/components/layout/SideNavBar/SideNavbar.tsx @@ -2,6 +2,7 @@ import clsx from 'classnames'; import { useContext, useState } from 'react'; import { FaBriefcase } from 'react-icons/fa'; import { MdChevronLeft, MdChevronRight, MdContactMail, MdHome } from 'react-icons/md'; +import { TbArrowBounce } from 'react-icons/tb'; import { useHistory } from 'react-router-dom'; import { ReactComponent as AdminPanelSettings } from '@/assets/images/admin-panel-settings.svg'; @@ -57,6 +58,12 @@ export const SideNavBar = () => { text="Leases & Licenses" showText={expanded} /> + setTrayPage(SidebarContextType.DISPOSITION)} + icon={} + text="Disposition" + showText={expanded} + /> setTrayPage(SidebarContextType.CONTACT)} icon={} diff --git a/source/frontend/src/components/layout/SideNavBar/SideTray.tsx b/source/frontend/src/components/layout/SideNavBar/SideTray.tsx index 64455f28ad..13c5c9197f 100644 --- a/source/frontend/src/components/layout/SideNavBar/SideTray.tsx +++ b/source/frontend/src/components/layout/SideNavBar/SideTray.tsx @@ -6,6 +6,7 @@ import { AdminTools, LeaseAndLicenses, ResearchTray } from '@/components/layout' import { AcquisitionTray } from './AcquisitionTray'; import { ContactTray } from './ContactTray'; +import { DispositionTray } from './DispositionTray'; import { ProjectTray } from './ProjectTray'; import * as Styled from './styles'; @@ -16,6 +17,7 @@ export enum SidebarContextType { RESEARCH = 'research', CONTACT = 'contact', ACQUISITION = 'acquisition', + DISPOSITION = 'disposition', } interface ISideTrayProps { @@ -44,6 +46,7 @@ export const SideTray = ({ context, setContext }: ISideTrayProps) => { [SidebarContextType.CONTACT, ], [SidebarContextType.ACQUISITION, ], [SidebarContextType.PROJECT, setShow(false)} />], + [SidebarContextType.DISPOSITION, ], ]); useEffect(() => { diff --git a/source/frontend/src/components/layout/SideNavBar/__snapshots__/SideNavbar.test.tsx.snap b/source/frontend/src/components/layout/SideNavBar/__snapshots__/SideNavbar.test.tsx.snap index 15323daf86..3b6343206f 100644 --- a/source/frontend/src/components/layout/SideNavBar/__snapshots__/SideNavbar.test.tsx.snap +++ b/source/frontend/src/components/layout/SideNavBar/__snapshots__/SideNavbar.test.tsx.snap @@ -281,6 +281,51 @@ exports[`SideNavbar display and logic renders 1`] = ` +