Repository: terraware/terraware-web
Pull request #3985: Replaced seed fund report usages of observation selectors
Author: login: tommylau523
Created: 2025-05-13T00:15:38Z | Merged: 2025-05-14T18:45:23Z



Diff:
diff --git a/src/api/types/generated-schema.ts b/src/api/types/generated-schema.ts
index eab2a738fb2a..5c8af39998ab 100644
--- a/src/api/types/generated-schema.ts
+++ b/src/api/types/generated-schema.ts
@@ -4970,7 +4970,10 @@ export interface components {
              * @description If the draft is associated with a project, its ID.
              */
             projectId?: number;
-            /** @example Europe/Paris */
+            /**
+             * @description Time zone name in IANA tz database format
+             * @example America/New_York
+             */
             timeZone?: string;
         };
         CreateDraftPlantingSiteResponsePayload: {
@@ -4998,7 +5001,10 @@ export interface components {
              */
             organizationId: number;
             subLocationNames?: string[];
-            /** @example Europe/Paris */
+            /**
+             * @description Time zone name in IANA tz database format
+             * @example America/New_York
+             */
             timeZone?: string;
             /** @enum {string} */
             type: "Seed Bank" | "Desalination" | "Reverse Osmosis" | "Nursery";
@@ -5113,7 +5119,10 @@ export interface components {
             organizationType?: "Government" | "NGO" | "Arboreta" | "Academia" | "ForProfit" | "Other";
             /** @description Non-empty additional description of organization when type is Other. */
             organizationTypeDetails?: string;
-            /** @example Europe/Paris */
+            /**
+             * @description Time zone name in IANA tz database format
+             * @example America/New_York
+             */
             timeZone?: string;
             /** @description Website of organization, no restrictions on format. */
             website?: string;
@@ -5157,7 +5166,10 @@ export interface components {
             plantingZones?: components["schemas"]["NewPlantingZonePayload"][];
             /** Format: int64 */
             projectId?: number;
-            /** @example Europe/Paris */
+            /**
+             * @description Time zone name in IANA tz database format
+             * @example America/New_York
+             */
             timeZone?: string;
         };
         CreatePlantingSiteResponsePayload: {
@@ -5556,7 +5568,10 @@ export interface components {
              * @description If the draft is associated with a project, its ID.
              */
             projectId?: number;
-            /** @example Europe/Paris */
+            /**
+             * @description Time zone name in IANA tz database format
+             * @example America/New_York
+             */
             timeZone?: string;
         };
         EmailVariablePayload: Omit<components["schemas"]["VariablePayload"], "type"> & {
@@ -5844,7 +5859,10 @@ export interface components {
             operationStartedDate?: string;
             /** Format: int64 */
             organizationId: number;
-            /** @example Europe/Paris */
+            /**
+             * @description Time zone name in IANA tz database format
+             * @example America/New_York
+             */
             timeZone?: string;
             /** @enum {string} */
             type: "Seed Bank" | "Desalination" | "Reverse Osmosis" | "Nursery";
@@ -7660,7 +7678,10 @@ export interface components {
              */
             role?: "Contributor" | "Manager" | "Admin" | "Owner" | "Terraformation Contact";
             tfContactUser?: components["schemas"]["TerraformationContactUserPayload"];
-            /** @example Europe/Paris */
+            /**
+             * @description Time zone name in IANA tz database format
+             * @example America/New_York
+             */
             timeZone?: string;
             /**
              * Format: int32
@@ -7855,7 +7876,10 @@ export interface components {
             plantingZones?: components["schemas"]["PlantingZonePayload"][];
             /** Format: int64 */
             projectId?: number;
-            /** @example Europe/Paris */
+            /**
+             * @description Time zone name in IANA tz database format
+             * @example America/New_York
+             */
             timeZone?: string;
         };
         PlantingSiteReportedPlantsPayload: {
@@ -8919,7 +8943,10 @@ export interface components {
             type: "Text";
         };
         TimeZonePayload: {
-            /** @example Europe/Paris */
+            /**
+             * @description Time zone name in IANA tz database format
+             * @example America/New_York
+             */
             id: string;
             /**
              * @description Long name of time zone, possibly including a city name. This name is guaranteed to be unique across all zones.
@@ -9186,7 +9213,10 @@ export interface components {
              * @description If the draft is associated with a project, its ID.
              */
             projectId?: number;
-            /** @example Europe/Paris */
+            /**
+             * @description Time zone name in IANA tz database format
+             * @example America/New_York
+             */
             timeZone?: string;
         };
         UpdateFacilityRequestPayload: {
@@ -9203,7 +9233,10 @@ export interface components {
             name: string;
             /** Format: date */
             operationStartedDate?: string;
-            /** @example Europe/Paris */
+            /**
+             * @description Time zone name in IANA tz database format
+             * @example America/New_York
+             */
             timeZone?: string;
         };
         UpdateFundingEntityRequestPayload: {
@@ -9257,7 +9290,10 @@ export interface components {
             organizationType?: "Government" | "NGO" | "Arboreta" | "Academia" | "ForProfit" | "Other";
             /** @description Non-empty additional description of organization when type is Other. */
             organizationTypeDetails?: string;
-            /** @example Europe/Paris */
+            /**
+             * @description Time zone name in IANA tz database format
+             * @example America/New_York
+             */
             timeZone?: string;
             website?: string;
         };
@@ -9292,7 +9328,10 @@ export interface components {
             plantingSeasons?: components["schemas"]["UpdatedPlantingSeasonPayload"][];
             /** Format: int64 */
             projectId?: number;
-            /** @example Europe/Paris */
+            /**
+             * @description Time zone name in IANA tz database format
+             * @example America/New_York
+             */
             timeZone?: string;
         };
         UpdatePlantingSubzoneRequestPayload: {
@@ -9438,7 +9477,10 @@ export interface components {
              * @example en
              */
             locale?: string;
-            /** @example Europe/Paris */
+            /**
+             * @description Time zone name in IANA tz database format
+             * @example America/New_York
+             */
             timeZone?: string;
         };
         /** @description Operation that replaces a single existing value with a new one. The new value will have the same list position as the existing one.
@@ -9653,7 +9695,10 @@ export interface components {
              * @example en
              */
             locale?: string;
-            /** @example Europe/Paris */
+            /**
+             * @description Time zone name in IANA tz database format
+             * @example America/New_York
+             */
             timeZone?: string;
             /**
              * @description Type of User. Could be Individual, Funder or DeviceManager
@@ -10086,9 +10131,9 @@ export interface operations {
     };
     listCohorts: {
         parameters: {
-            query: {
+            query?: {
                 /** @description If specified, retrieve associated entities to the supplied depth. For example, 'participant' depth will return the participants associated to the cohort. */
-                cohortDepth: "Cohort" | "Participant";
+                cohortDepth?: "Cohort" | "Participant";
             };
             header?: never;
             path?: never;
@@ -10133,9 +10178,9 @@ export interface operations {
     };
     getCohort: {
         parameters: {
-            query: {
+            query?: {
                 /** @description If specified, retrieve associated entities to the supplied depth. For example, 'participant' depth will return the participants associated to the cohort. */
-                cohortDepth: "Cohort" | "Participant";
+                cohortDepth?: "Cohort" | "Participant";
             };
             header?: never;
             path: {
diff --git a/src/components/SeedFundReports/LocationSelection/PlantingSite.tsx b/src/components/SeedFundReports/LocationSelection/PlantingSite.tsx
index cfef0da5013e..bcb12f2abc03 100644
--- a/src/components/SeedFundReports/LocationSelection/PlantingSite.tsx
+++ b/src/components/SeedFundReports/LocationSelection/PlantingSite.tsx
@@ -2,6 +2,7 @@ import React, { useEffect, useMemo, useState } from 'react';
 
 import { Box, Grid } from '@mui/material';
 import { TableColumnType } from '@terraware/web-components';
+import { getDateDisplayValue } from '@terraware/web-components/utils';
 
 import { LocationSectionProps } from 'src/components/SeedFundReports/LocationSelection';
 import { InfoField, infoCardStyles } from 'src/components/SeedFundReports/LocationSelection/InfoField';
@@ -10,21 +11,12 @@ import { transformNumericValue } from 'src/components/SeedFundReports/LocationSe
 import OverviewItemCard from 'src/components/common/OverviewItemCard';
 import Table from 'src/components/common/table';
 import { useOrganization } from 'src/providers';
-import {
-  selectCurrentObservation,
-  selectLatestObservation,
-  selectNextObservation,
-  selectObservation,
-} from 'src/redux/features/observations/observationsSelectors';
-import { selectPlantingSite, selectSiteReportedPlants } from 'src/redux/features/tracking/trackingSelectors';
-import { requestSiteReportedPlants } from 'src/redux/features/tracking/trackingThunks';
-import { useAppDispatch, useAppSelector } from 'src/redux/store';
+import { usePlantingSiteData } from 'src/providers/Tracking/PlantingSiteContext';
 import { SpeciesService } from 'src/services';
 import strings from 'src/strings';
 import { ReportPlantingSite } from 'src/types/Report';
 import { GrowthForm, Species } from 'src/types/Species';
 import useDeviceInfo from 'src/utils/useDeviceInfo';
-import { useDefaultTimeZone } from 'src/utils/useTimeZoneUtils';
 
 type PlantingSiteSpecies = {
   id: number;
@@ -60,23 +52,19 @@ const LocationSectionPlantingSite = (props: LocationSectionProps): JSX.Element =
   const { isMobile } = useDeviceInfo();
 
   const { selectedOrganization } = useOrganization();
-  const dispatch = useAppDispatch();
-  const defaultTimeZone = useDefaultTimeZone();
-
-  const defaultTZ = defaultTimeZone.get().id;
-
-  // The calls to satisfy this data are all dispatched in the parent ReportForm component
-  const reportedPlants = useAppSelector((state) => selectSiteReportedPlants(state, location.id));
-  const plantingSite = useAppSelector((state) => selectPlantingSite(state, location.id));
-  const currentObservation = useAppSelector((state) => selectCurrentObservation(state, location.id, defaultTZ));
-  const nextObservation = useAppSelector((state) => selectNextObservation(state, location.id, defaultTZ));
-  const latestObservation = useAppSelector((state) => selectLatestObservation(state, location.id, defaultTZ));
-  const currentObservationData = useAppSelector((state) =>
-    selectObservation(state, location.id, Number(currentObservation?.observationId))
-  );
-  const nextObservationData = useAppSelector((state) =>
-    selectObservation(state, location.id, Number(nextObservation?.observationId))
-  );
+
+  const {
+    plantingSite,
+    setSelectedPlantingSite,
+    plantingSiteReportedPlants,
+    currentObservation,
+    latestResult,
+    nextObservation,
+  } = usePlantingSiteData();
+
+  useEffect(() => {
+    setSelectedPlantingSite(location.id);
+  }, [location]);
 
   const [allSpecies, setAllSpecies] = useState<Species[]>();
   const [plantingSiteSpecies, setPlantingSiteSpecies] = useState<PlantingSiteSpecies[]>([]);
@@ -84,24 +72,18 @@ const LocationSectionPlantingSite = (props: LocationSectionProps): JSX.Element =
 
   const smallItemGridWidth = () => (isMobile ? 12 : 4);
 
-  useEffect(() => {
-    if (plantingSite?.id) {
-      void dispatch(requestSiteReportedPlants(plantingSite.id));
-    }
-  }, [plantingSite?.id, dispatch]);
-
   useEffect(() => {
     if (plantingSite) {
       const zoneDensities: Record<string, number | string> = {};
       plantingSite.plantingZones?.forEach((zone) => {
-        if (latestObservation) {
-          const zoneFromObs = latestObservation.plantingZones.find((obsZone) => obsZone.plantingZoneId === zone.id);
+        if (latestResult) {
+          const zoneFromObs = latestResult.plantingZones.find((obsZone) => obsZone.plantingZoneId === zone.id);
           zoneDensities[zone.name] = zoneFromObs?.plantingDensity ?? '';
         }
       });
       setPlantingDensity(zoneDensities);
     }
-  }, [plantingSite, latestObservation]);
+  }, [plantingSite, latestResult]);
 
   useEffect(() => {
     if (selectedOrganization.id !== -1) {
@@ -155,22 +137,22 @@ const LocationSectionPlantingSite = (props: LocationSectionProps): JSX.Element =
   };
 
   const estimatedPlants = useMemo(() => {
-    return latestObservation?.estimatedPlants?.toString();
-  }, [latestObservation?.estimatedPlants]);
+    return latestResult?.estimatedPlants?.toString();
+  }, [latestResult?.estimatedPlants]);
 
   const livePlants = useMemo(() => {
-    return latestObservation?.species.reduce((acc, sp) => (acc = acc + sp.permanentLive), 0);
-  }, [latestObservation]);
+    return latestResult?.species.reduce((acc, sp) => (acc = acc + sp.permanentLive), 0);
+  }, [latestResult]);
 
   const deadPlants = useMemo(() => {
-    return latestObservation?.species.reduce((acc, sp) => (acc = acc + sp.cumulativeDead), 0);
-  }, [latestObservation]);
+    return latestResult?.species.reduce((acc, sp) => (acc = acc + sp.cumulativeDead), 0);
+  }, [latestResult]);
 
   const numberOfPlots = useMemo(() => {
-    return latestObservation?.plantingZones.flatMap((pz) =>
+    return latestResult?.plantingZones.flatMap((pz) =>
       pz.plantingSubzones.flatMap((subzone) => subzone.monitoringPlots)
     ).length;
-  }, [latestObservation]);
+  }, [latestResult]);
 
   const markedAsComplete = useMemo(() => {
     if (plantingSite) {
@@ -209,14 +191,21 @@ const LocationSectionPlantingSite = (props: LocationSectionProps): JSX.Element =
   }, [plantingSite, plantingDensity]);
 
   const currentNextObservationDates = useMemo(() => {
-    if (currentObservationData) {
-      return `${currentObservationData.startDate} - ${currentObservationData.endDate}`;
+    if (currentObservation) {
+      return `${currentObservation.startDate} - ${currentObservation.endDate}`;
     }
-    if (nextObservationData) {
-      return `${nextObservationData.startDate} - ${nextObservationData.endDate}`;
+    if (nextObservation) {
+      return `${nextObservation.startDate} - ${nextObservation.endDate}`;
     }
     return '';
-  }, [currentObservationData, nextObservationData]);
+  }, [currentObservation, nextObservation]);
+
+  const latestObservationDateString = useMemo(() => {
+    if (latestResult?.completedTime && plantingSite) {
+      const completedDate = getDateDisplayValue(latestResult.completedTime, plantingSite.timeZone);
+      return `${latestResult.startDate} - ${completedDate}`;
+    }
+  }, [latestResult, plantingSite]);
 
   return (
     <>
@@ -230,7 +219,9 @@ const LocationSectionPlantingSite = (props: LocationSectionProps): JSX.Element =
           onChange={(value) => onUpdateLocation('totalPlantingSiteArea', transformNumericValue(value, { min: 0 }))}
           type='text'
           errorText={
-            validate && (location as ReportPlantingSite).totalPlantingSiteArea == null ? strings.REQUIRED_FIELD : ''
+            validate && (location as ReportPlantingSite).totalPlantingSiteArea === undefined
+              ? strings.REQUIRED_FIELD
+              : ''
           }
           tooltipTitle={strings.REPORT_TOTAL_PLANTING_SITE_AREA_INFO}
         />
@@ -246,7 +237,7 @@ const LocationSectionPlantingSite = (props: LocationSectionProps): JSX.Element =
           onChange={(value) => onUpdateLocation('totalPlantedArea', transformNumericValue(value, { min: 0 }))}
           type='text'
           errorText={
-            validate && (location as ReportPlantingSite).totalPlantedArea == null ? strings.REQUIRED_FIELD : ''
+            validate && (location as ReportPlantingSite).totalPlantedArea === undefined ? strings.REQUIRED_FIELD : ''
           }
           tooltipTitle={strings.REPORT_TOTAL_PLANTED_AREA_INFO}
         />
@@ -265,7 +256,7 @@ const LocationSectionPlantingSite = (props: LocationSectionProps): JSX.Element =
           type='text'
           helper={strings.TOTAL_TREES_PLANTED_HELPER_TEXT}
           errorText={
-            validate && (location as ReportPlantingSite).totalTreesPlanted == null ? strings.REQUIRED_FIELD : ''
+            validate && (location as ReportPlantingSite).totalTreesPlanted === undefined ? strings.REQUIRED_FIELD : ''
           }
           tooltipTitle={strings.REPORT_TOTAL_TREES_PLANTED_INFO}
         />
@@ -282,7 +273,7 @@ const LocationSectionPlantingSite = (props: LocationSectionProps): JSX.Element =
           type='text'
           helper={strings.TOTAL_PLANTS_PLANTED_HELPER_TEXT}
           errorText={
-            validate && (location as ReportPlantingSite).totalPlantsPlanted == null ? strings.REQUIRED_FIELD : ''
+            validate && (location as ReportPlantingSite).totalPlantsPlanted === undefined ? strings.REQUIRED_FIELD : ''
           }
           tooltipTitle={strings.REPORT_TOTAL_NON_TREES_PLANTED_INFO}
         />
@@ -304,7 +295,9 @@ const LocationSectionPlantingSite = (props: LocationSectionProps): JSX.Element =
           editable={editable}
           onChange={(value) => onUpdateLocation('mortalityRate', transformNumericValue(value, { min: 0, max: 100 }))}
           type='text'
-          errorText={validate && (location as ReportPlantingSite).mortalityRate == null ? strings.REQUIRED_FIELD : ''}
+          errorText={
+            validate && (location as ReportPlantingSite).mortalityRate === undefined ? strings.REQUIRED_FIELD : ''
+          }
           tooltipTitle={strings.REPORT_MORTALITY_RATE_INFO}
         />
       </Grid>
@@ -325,13 +318,13 @@ const LocationSectionPlantingSite = (props: LocationSectionProps): JSX.Element =
         </Grid>
       )}
 
-      {latestObservation && (
+      {latestResult && (
         <>
           <Grid item xs={smallItemGridWidth()}>
             <OverviewItemCard
               isEditable={false}
               title={strings.MOST_RECENT_OBSERVATION}
-              contents={`${latestObservation.startDate} - ${latestObservation.completedDate}`}
+              contents={latestObservationDateString}
               sx={infoCardStyles}
             />
           </Grid>
@@ -339,7 +332,7 @@ const LocationSectionPlantingSite = (props: LocationSectionProps): JSX.Element =
             <OverviewItemCard
               isEditable={false}
               title={strings.NUMBER_OF_PLOTS_IN_MOST_RECENT_OBSERVATION}
-              contents={numberOfPlots || ''}
+              contents={numberOfPlots}
               sx={infoCardStyles}
             />
           </Grid>
@@ -355,7 +348,7 @@ const LocationSectionPlantingSite = (props: LocationSectionProps): JSX.Element =
             <OverviewItemCard
               isEditable={false}
               title={strings.TOTAL_PLANTS_OBSERVED}
-              contents={latestObservation.totalPlants}
+              contents={latestResult?.totalPlants}
               sx={infoCardStyles}
             />
           </Grid>
@@ -363,7 +356,7 @@ const LocationSectionPlantingSite = (props: LocationSectionProps): JSX.Element =
             <OverviewItemCard
               isEditable={false}
               title={strings.LIVE_PLANTS_OBSERVED}
-              contents={livePlants || ''}
+              contents={livePlants}
               sx={infoCardStyles}
             />
           </Grid>
@@ -379,7 +372,7 @@ const LocationSectionPlantingSite = (props: LocationSectionProps): JSX.Element =
             <OverviewItemCard
               isEditable={false}
               title={strings.SPECIES_OBSERVED}
-              contents={latestObservation.totalSpecies}
+              contents={latestResult?.totalSpecies}
               sx={infoCardStyles}
             />
           </Grid>
@@ -395,7 +388,7 @@ const LocationSectionPlantingSite = (props: LocationSectionProps): JSX.Element =
             <OverviewItemCard
               isEditable={false}
               title={strings.MORTALITY_RATE_PERCENT}
-              contents={latestObservation.mortalityRate ?? null}
+              contents={latestResult.mortalityRate}
               sx={infoCardStyles}
             />
           </Grid>
@@ -404,7 +397,7 @@ const LocationSectionPlantingSite = (props: LocationSectionProps): JSX.Element =
               <OverviewItemCard
                 isEditable={false}
                 title={strings.PLANTING_PROGRESS_PERCENT}
-                contents={reportedPlants?.progressPercent || ''}
+                contents={plantingSiteReportedPlants?.progressPercent}
                 sx={infoCardStyles}
               />
             </Grid>
@@ -423,7 +416,7 @@ const LocationSectionPlantingSite = (props: LocationSectionProps): JSX.Element =
             <OverviewItemCard
               isEditable={false}
               title={strings.EST_TOTAL_PLANTS_PLANTING_DENSITY_AREA}
-              contents={estimatedPlants ? `${estimatedPlants} ${strings.PLANTS_PER_HECTARE}` : ''}
+              contents={estimatedPlants}
               sx={infoCardStyles}
             />
           </Grid>
diff --git a/src/providers/Tracking/PlantingSiteContext.tsx b/src/providers/Tracking/PlantingSiteContext.tsx
index 3ae22bba6a0f..79053a4bbd74 100644
--- a/src/providers/Tracking/PlantingSiteContext.tsx
+++ b/src/providers/Tracking/PlantingSiteContext.tsx
@@ -20,7 +20,11 @@ export type PlantingSiteData = {
   observationResults?: ObservationResultsPayload[];
   observationSummaries?: ObservationSummary[];
 
-  latestObservation?: ObservationResultsPayload;
+  currentObservation?: Observation;
+  latestObservation?: Observation;
+  nextObservation?: Observation;
+
+  latestResult?: ObservationResultsPayload;
 };
 
 // default values pointing to nothing
diff --git a/src/providers/Tracking/PlantingSiteProvider.tsx b/src/providers/Tracking/PlantingSiteProvider.tsx
index e4c74cb8d2d5..6e74214f237e 100644
--- a/src/providers/Tracking/PlantingSiteProvider.tsx
+++ b/src/providers/Tracking/PlantingSiteProvider.tsx
@@ -173,7 +173,7 @@ const PlantingSiteProvider = ({ children }: Props) => {
     }
   }, [reportedPlantsResponse]);
 
-  const latestObservation = useMemo(() => {
+  const latestResult = useMemo(() => {
     return observationResults?.find(
       (result) =>
         (result.state === 'Completed' || result.state === 'Abandoned') &&
@@ -182,6 +182,29 @@ const PlantingSiteProvider = ({ children }: Props) => {
     );
   }, [observationResults]);
 
+  const latestObservation = useMemo(() => {
+    return observations?.find(
+      (observation) =>
+        (observation.state === 'Completed' || observation.state === 'Abandoned') &&
+        observation.isAdHoc === false &&
+        observation.type === 'Monitoring'
+    );
+  }, [observationResults]);
+
+  const currentObservation = useMemo(() => {
+    return observations?.find(
+      (observation) =>
+        observation.state === 'InProgress' && observation.isAdHoc === false && observation.type === 'Monitoring'
+    );
+  }, [observationResults]);
+
+  const nextObservation = useMemo(() => {
+    return observations?.find(
+      (observation) =>
+        observation.state === 'Upcoming' && observation.isAdHoc === false && observation.type === 'Monitoring'
+    );
+  }, [observationResults]);
+
   const value = useMemo(
     (): PlantingSiteData => ({
       acceleratorOrganizationId,
@@ -196,7 +219,10 @@ const PlantingSiteProvider = ({ children }: Props) => {
       observationResults,
       observationSummaries,
       setSelectedPlantingSite,
+      currentObservation,
       latestObservation,
+      nextObservation,
+      latestResult,
     }),
     [
       acceleratorOrganizationId,
@@ -211,7 +237,10 @@ const PlantingSiteProvider = ({ children }: Props) => {
       observations,
       observationResults,
       setSelectedPlantingSite,
+      currentObservation,
       latestObservation,
+      nextObservation,
+      latestResult,
     ]
   );
 
diff --git a/src/redux/features/cohorts/cohortsAsyncThunks.ts b/src/redux/features/cohorts/cohortsAsyncThunks.ts
index 9afde2b7a184..ca9e5df14d13 100644
--- a/src/redux/features/cohorts/cohortsAsyncThunks.ts
+++ b/src/redux/features/cohorts/cohortsAsyncThunks.ts
@@ -4,7 +4,6 @@ import { setCohortAction, setCohortsAction } from 'src/redux/features/cohorts/co
 import CohortService, {
   CreateCohortResponsePayload,
   DeleteCohortResponsePayload,
-  ListCohortsRequestDepth,
   UpdateCohortResponsePayload,
 } from 'src/services/CohortService';
 import { Response2 } from 'src/services/HttpService';
@@ -17,15 +16,14 @@ export const requestCohorts = createAsyncThunk(
   async (
     request: {
       locale: string | null;
-      depth?: ListCohortsRequestDepth;
       search?: SearchNodePayload;
       searchSortOrder?: SearchSortOrder;
     },
     { dispatch, rejectWithValue }
   ) => {
-    const { depth, locale, search, searchSortOrder } = request;
+    const { locale, search, searchSortOrder } = request;
 
-    const response = await CohortService.listCohorts(locale, search, searchSortOrder, depth);
+    const response = await CohortService.listCohorts(locale, search, searchSortOrder);
 
     if (response !== null && response.requestSucceeded && response?.cohorts !== undefined) {
       dispatch(setCohortsAction({ error: response.error, cohorts: response.cohorts }));
@@ -38,9 +36,8 @@ export const requestCohorts = createAsyncThunk(
 
 export const requestCohort = createAsyncThunk(
   'cohorts/get',
-  async (request: { cohortId: number; depth?: ListCohortsRequestDepth }, { dispatch, rejectWithValue }) => {
-    const { depth } = request;
-    const response: Response2<Cohort> = await CohortService.getCohort(request.cohortId, depth);
+  async (request: { cohortId: number }, { dispatch, rejectWithValue }) => {
+    const response: Response2<Cohort> = await CohortService.getCohort(request.cohortId);
 
     if (response !== null && response.requestSucceeded && response.data !== undefined) {
       dispatch(setCohortAction({ error: response.error, cohorts: [response.data] }));
diff --git a/src/redux/features/observations/observationsSelectors.ts b/src/redux/features/observations/observationsSelectors.ts
index 726936a9229e..2463d7526c38 100644
--- a/src/redux/features/observations/observationsSelectors.ts
+++ b/src/redux/features/observations/observationsSelectors.ts
@@ -251,20 +251,6 @@ export const selectRescheduleObservation = (state: RootState, requestId: string)
 export const selectReplaceObservationPlot = (state: RootState, requestId: string) =>
   state.replaceObservationPlot[requestId];
 
-// get the current observation for a planting site
-export const selectCurrentObservation = createCachedSelector(
-  (state: RootState, plantingSiteId: number, defaultTimeZoneId: string) =>
-    searchObservations(state, plantingSiteId, defaultTimeZoneId, '', [], ['InProgress']),
-  (observationsResults: ObservationResults[] | undefined) => observationsResults?.[0]
-)((state: RootState, plantingSiteId: number, defaultTimeZoneId: string) => `${plantingSiteId}-${defaultTimeZoneId}`);
-
-// get the next observation for a planting site
-export const selectNextObservation = createCachedSelector(
-  (state: RootState, plantingSiteId: number, defaultTimeZoneId: string) =>
-    searchObservations(state, plantingSiteId, defaultTimeZoneId, '', [], ['Upcoming']),
-  (observationsResults: ObservationResults[] | undefined) => observationsResults?.[0]
-)((state: RootState, plantingSiteId: number, defaultTimeZoneId: string) => `${plantingSiteId}-${defaultTimeZoneId}`);
-
 export const selectPlantingSiteObservationSummaries = (requestId: string) => (state: RootState) =>
   state.plantingSiteObservationsSummaries[requestId];
 
diff --git a/src/redux/features/tracking/trackingSelectors.ts b/src/redux/features/tracking/trackingSelectors.ts
index 0da4d12637ba..0edc1fd6e364 100644
--- a/src/redux/features/tracking/trackingSelectors.ts
+++ b/src/redux/features/tracking/trackingSelectors.ts
@@ -24,22 +24,6 @@ export const selectPlantingSitesError = (state: RootState) => state.tracking?.er
 export const selectPlantingSite = (state: RootState, plantingSiteId: number) =>
   selectPlantingSites(state)?.find((site: PlantingSite) => site.id === plantingSiteId);
 
-export const selectOrgPlantingSite = (state: RootState, plantingSiteId: number, orgId: number) =>
-  selectOrgPlantingSites(orgId)(state)?.find((site: PlantingSite) => site.id === plantingSiteId);
-
-export const selectSiteReportedPlants = (state: RootState, plantingSiteId: number) =>
-  state.siteReportedPlantsResults[plantingSiteId]?.site;
-
-export const selectMultipleSitesTotalPlants = (state: RootState, plantingSiteIds: string[]) => {
-  return plantingSiteIds.reduce((total, psId) => {
-    const siteData = state.siteReportedPlantsResults[+psId]?.site;
-    return total + (siteData?.totalPlants ?? 0);
-  }, 0);
-};
-
-export const selectSiteReportedPlantsError = (state: RootState, plantingSiteId: number) =>
-  state.siteReportedPlantsResults[plantingSiteId]?.error;
-
 export const selectMonitoringPlots = (state: RootState, requestId: string) => state.monitoringPlots[requestId];
 
 export const selectPlantingSiteHistory = (state: RootState, requestId: string) => state.plantingSiteHistory[requestId];
diff --git a/src/redux/features/tracking/trackingThunks.ts b/src/redux/features/tracking/trackingThunks.ts
index d1402cdb6cf9..cbf0e3e67974 100644
--- a/src/redux/features/tracking/trackingThunks.ts
+++ b/src/redux/features/tracking/trackingThunks.ts
@@ -11,7 +11,6 @@ import {
   setPlantingSiteAction,
   setPlantingSitesAction,
   setPlantingSitesSearchResultsAction,
-  setSitePopulationAction,
   setSiteReportedPlantsAction,
 } from './trackingSlice';
 
@@ -59,23 +58,6 @@ export const requestPlantingSites = createAsyncThunk(
   }
 );
 
-export const requestSitePopulation = (organizationId: number, siteId: number) => {
-  return async (dispatch: Dispatch, _getState: () => RootState) => {
-    try {
-      const response = await TrackingService.getTotalPlantsInZones(organizationId, siteId);
-      if (response) {
-        dispatch(setSitePopulationAction({ error: undefined, zones: response }));
-      } else {
-        dispatch(setSitePopulationAction({ error: 'Error getting site population', zones: undefined }));
-      }
-    } catch (e) {
-      // should not happen, the response above captures any http request errors
-      // eslint-disable-next-line no-console
-      console.error('Error dispatching site population', e);
-    }
-  };
-};
-
 export const requestPlantingSitesSearchResults = (organizationId: number) => {
   return async (dispatch: Dispatch, _getState: () => RootState) => {
     try {
diff --git a/src/scenes/AcceleratorRouter/Cohorts/CohortsListView.tsx b/src/scenes/AcceleratorRouter/Cohorts/CohortsListView.tsx
index d015ad8e4226..caab40750ac7 100644
--- a/src/scenes/AcceleratorRouter/Cohorts/CohortsListView.tsx
+++ b/src/scenes/AcceleratorRouter/Cohorts/CohortsListView.tsx
@@ -84,7 +84,7 @@ const CohortsListView = ({ filterModifiers, extraTableFilters }: CohortsListView
   const dispatchSearchRequest = useCallback(
     (locale: string | null, search: SearchNodePayload, searchSortOrder: SearchSortOrder) => {
       setHasFilters(search.children.length > 0);
-      void dispatch(requestCohorts({ locale, depth: 'Participant', search, searchSortOrder }));
+      void dispatch(requestCohorts({ locale, search, searchSortOrder }));
     },
     [dispatch]
   );
diff --git a/src/scenes/Home/TerrawareHomeView/PlantingSiteStats.tsx b/src/scenes/Home/TerrawareHomeView/PlantingSiteStats.tsx
index ceb588944c1d..dfa8ef4fe412 100644
--- a/src/scenes/Home/TerrawareHomeView/PlantingSiteStats.tsx
+++ b/src/scenes/Home/TerrawareHomeView/PlantingSiteStats.tsx
@@ -28,7 +28,7 @@ export const PlantingSiteStats = () => {
   const { selectedOrganization } = useOrganization();
   const { token } = useMapboxToken();
 
-  const { allPlantingSites, plantingSite, setSelectedPlantingSite, latestObservation, plantingSiteReportedPlants } =
+  const { allPlantingSites, plantingSite, setSelectedPlantingSite, latestResult, plantingSiteReportedPlants } =
     usePlantingSiteData();
   const { countries } = useLocalization();
 
@@ -51,12 +51,12 @@ export const PlantingSiteStats = () => {
   }, [plantingSite]);
 
   const latestObservationCompletedTime = useMemo(() => {
-    if (latestObservation?.completedTime && plantingSite) {
-      return getDateDisplayValue(latestObservation.completedTime, plantingSite.timeZone);
+    if (latestResult?.completedTime && plantingSite) {
+      return getDateDisplayValue(latestResult.completedTime, plantingSite.timeZone);
     } else {
       return '';
     }
-  }, [latestObservation, plantingSite]);
+  }, [latestResult, plantingSite]);
 
   const totalPlants = useMemo(() => plantingSiteReportedPlants?.totalPlants ?? 0, [plantingSiteReportedPlants]);
   const totalSpecies = useMemo(() => plantingSiteReportedPlants?.species?.length ?? 0, [plantingSiteReportedPlants]);
@@ -170,7 +170,7 @@ export const PlantingSiteStats = () => {
               label={strings.MORTALITY_RATE}
               showBorder={!isDesktop}
               showLink={false}
-              value={latestObservation?.mortalityRate ? `${latestObservation.mortalityRate}%` : ''}
+              value={latestResult?.mortalityRate ? `${latestResult.mortalityRate}%` : ''}
             />
           </Grid>
 
diff --git a/src/scenes/PlantsDashboardRouter/PlantsDashboardView.tsx b/src/scenes/PlantsDashboardRouter/PlantsDashboardView.tsx
index 474b6f99a437..5b065f769a23 100644
--- a/src/scenes/PlantsDashboardRouter/PlantsDashboardView.tsx
+++ b/src/scenes/PlantsDashboardRouter/PlantsDashboardView.tsx
@@ -41,11 +41,11 @@ export default function PlantsDashboardView({ projectId, organizationId }: Plant
     setSelectedPlantingSite,
     allPlantingSites,
     plantingSite,
-    latestObservation,
+    latestResult,
     observationSummaries,
   } = usePlantingSiteData();
 
-  const hasObservations = useMemo(() => !!latestObservation, [latestObservation]);
+  const hasObservations = useMemo(() => !!latestResult, [latestResult]);
 
   const sitePlantingComplete = useMemo(() => {
     return (
@@ -59,21 +59,21 @@ export default function PlantsDashboardView({ projectId, organizationId }: Plant
     [setPlantsDashboardPreferences]
   );
 
-  const latestObservationId = useMemo(() => {
-    return latestObservation?.observationId;
-  }, [latestObservation]);
+  const latestResultId = useMemo(() => {
+    return latestResult?.observationId;
+  }, [latestResult]);
 
   const geometryChangedNote = useMemo(() => {
-    if (latestObservation?.completedTime && plantingSite?.plantingZones?.length) {
+    if (latestResult?.completedTime && plantingSite?.plantingZones?.length) {
       const siteBoundaryModifiedTime = plantingSite.plantingZones.reduce(
         (maxTime, zone) => (isAfter(zone.boundaryModifiedTime, maxTime) ? zone.boundaryModifiedTime : maxTime),
         plantingSite.plantingZones[0].boundaryModifiedTime
       );
-      return isAfter(siteBoundaryModifiedTime, latestObservation.completedTime);
+      return isAfter(siteBoundaryModifiedTime, latestResult.completedTime);
     } else {
       return false;
     }
-  }, [latestObservation, plantingSite]);
+  }, [latestResult, plantingSite]);
 
   useEffect(() => {
     const orgId = organizationId ?? selectedOrganization.id;
@@ -89,31 +89,31 @@ export default function PlantsDashboardView({ projectId, organizationId }: Plant
     </Grid>
   );
 
-  const getLatestObservationLink = useCallback(() => {
-    const allMonitoringPlots = latestObservation?.plantingZones.flatMap((pz) =>
+  const renderLatestObservationLink = useCallback(() => {
+    const allMonitoringPlots = latestResult?.plantingZones.flatMap((pz) =>
       pz.plantingSubzones.flatMap((sz) => sz.monitoringPlots)
     );
     const maxCompletedTime = allMonitoringPlots?.reduce(
       (acc, plot) => (isAfter(plot.completedTime, acc) ? plot.completedTime : acc),
       allMonitoringPlots[0].completedTime
     );
-    return plantingSite && latestObservation?.completedTime ? (
+    return plantingSite && latestResult?.completedTime ? (
       <Link
         fontSize={'16px'}
         to={APP_PATHS.OBSERVATION_DETAILS.replace(':plantingSiteId', plantingSite?.id.toString()).replace(
           ':observationId',
-          latestObservation.observationId.toString()
+          latestResult.observationId.toString()
         )}
       >
         {strings.formatString(
           strings.DATE_OBSERVATION,
-          DateTime.fromISO(maxCompletedTime || latestObservation.completedTime).toFormat('yyyy-MM-dd')
+          DateTime.fromISO(maxCompletedTime || latestResult.completedTime).toFormat('yyyy-MM-dd')
         )}
       </Link>
     ) : (
       ''
     );
-  }, [latestObservation]);
+  }, [latestResult]);
 
   const renderMortalityRate = useCallback(
     () =>
@@ -131,7 +131,7 @@ export default function PlantsDashboardView({ projectId, organizationId }: Plant
                 {strings.MORTALITY_RATE}
               </Typography>
               {hasObservations && (
-                <Typography>{strings.formatString(strings.AS_OF_X, getLatestObservationLink())}</Typography>
+                <Typography>{strings.formatString(strings.AS_OF_X, renderLatestObservationLink())}</Typography>
               )}
             </Box>
           </Grid>
@@ -140,7 +140,7 @@ export default function PlantsDashboardView({ projectId, organizationId }: Plant
           </Grid>
         </>
       ) : undefined,
-    [plantingSite, getLatestObservationLink, hasObservations]
+    [plantingSite, renderLatestObservationLink, hasObservations]
   );
 
   const renderTotalPlantsAndSpecies = () => (
@@ -180,7 +180,7 @@ export default function PlantsDashboardView({ projectId, organizationId }: Plant
                 {strings.PLANTING_DENSITY}
               </Typography>
               {hasObservations && (
-                <Typography>{strings.formatString(strings.AS_OF_X, getLatestObservationLink())}</Typography>
+                <Typography>{strings.formatString(strings.AS_OF_X, renderLatestObservationLink())}</Typography>
               )}
             </Box>
           </Grid>
@@ -189,7 +189,7 @@ export default function PlantsDashboardView({ projectId, organizationId }: Plant
           </Grid>
         </>
       ) : undefined,
-    [plantingSite, sitePlantingComplete, hasObservations, getLatestObservationLink]
+    [plantingSite, sitePlantingComplete, hasObservations, renderLatestObservationLink]
   );
 
   const renderPlantingSiteTrends = useCallback(
@@ -229,7 +229,7 @@ export default function PlantsDashboardView({ projectId, organizationId }: Plant
                 {strings.SITE_MAP}
               </Typography>
               {hasObservations && (
-                <Typography>{strings.formatString(strings.AS_OF_X, getLatestObservationLink())}</Typography>
+                <Typography>{strings.formatString(strings.AS_OF_X, renderLatestObservationLink())}</Typography>
               )}
             </Box>
           </Grid>
@@ -238,7 +238,7 @@ export default function PlantsDashboardView({ projectId, organizationId }: Plant
           </Grid>
         </>
       ) : undefined,
-    [plantingSite, getLatestObservationLink, hasObservations]
+    [plantingSite, renderLatestObservationLink, hasObservations]
   );
 
   const renderSimpleSiteMap = useCallback(
@@ -286,14 +286,14 @@ export default function PlantsDashboardView({ projectId, organizationId }: Plant
 
   const observationHectares = useMemo(() => {
     const totalSquareMeters =
-      latestObservation?.plantingZones
+      latestResult?.plantingZones
         .flatMap((pz) =>
           pz.plantingSubzones.flatMap((psz) => psz.monitoringPlots.map((mp) => mp.sizeMeters * mp.sizeMeters))
         )
         .reduce((acc, area) => acc + area, 0) ?? 0;
 
     return totalSquareMeters * SQ_M_TO_HECTARES;
-  }, [latestObservation]);
+  }, [latestResult]);
 
   const getDashboardSubhead = useCallback(() => {
     if (!plantingSite) {
@@ -310,7 +310,7 @@ export default function PlantsDashboardView({ projectId, organizationId }: Plant
       ? (strings.formatString(
           strings.DASHBOARD_HEADER_TEXT_SINGLE_OBSERVATION,
           <b>{strings.formatString(strings.X_HECTARES, <FormattedNumber value={observationHectares} />)}</b>,
-          <b>{getLatestObservationLink()}</b>
+          <b>{renderLatestObservationLink()}</b>
         ) as string)
       : (strings.formatString(
           strings.DASHBOARD_HEADER_TEXT_V2,
@@ -338,7 +338,7 @@ export default function PlantsDashboardView({ projectId, organizationId }: Plant
   return (
     <PlantsPrimaryPage
       title={strings.DASHBOARD}
-      text={latestObservationId ? getDashboardSubhead() : undefined}
+      text={latestResultId ? getDashboardSubhead() : undefined}
       pagePath={
         projectId
           ? APP_PATHS.ACCELERATOR_PROJECT_VIEW.replace(':projectId', projectId.toString())
@@ -350,7 +350,7 @@ export default function PlantsDashboardView({ projectId, organizationId }: Plant
       setPlantsSitePreferences={onPreferences}
       newHeader={true}
       showGeometryNote={geometryChangedNote}
-      latestObservationId={latestObservationId}
+      latestObservationId={latestResultId}
       projectId={projectId}
       organizationId={organizationId}
       isEmptyState={plantingSite === undefined}
diff --git a/src/scenes/PlantsDashboardRouter/components/MortalityRateCard.tsx b/src/scenes/PlantsDashboardRouter/components/MortalityRateCard.tsx
index f78d318710f7..ec79a7126530 100644
--- a/src/scenes/PlantsDashboardRouter/components/MortalityRateCard.tsx
+++ b/src/scenes/PlantsDashboardRouter/components/MortalityRateCard.tsx
@@ -13,7 +13,7 @@ import LiveDeadPlantsPerSpeciesCard from './LiveDeadPlantsPerSpeciesCard';
 
 export default function MortalityRateCard(): JSX.Element {
   const theme = useTheme();
-  const { latestObservation } = usePlantingSiteData();
+  const { latestResult } = usePlantingSiteData();
   const { isDesktop } = useDeviceInfo();
 
   const separatorStyles = {
@@ -42,19 +42,15 @@ export default function MortalityRateCard(): JSX.Element {
         </Box>
         <Box display='flex' sx={{ flexFlow: 'row wrap' }} marginTop={1}>
           <Typography fontSize='48px' fontWeight={600} lineHeight={1}>
-            {latestObservation?.mortalityRate !== undefined ? (
-              <FormattedNumber value={latestObservation.mortalityRate} />
-            ) : (
-              '-'
-            )}
+            {latestResult?.mortalityRate !== undefined ? <FormattedNumber value={latestResult.mortalityRate} /> : '-'}
           </Typography>
-          {latestObservation?.mortalityRate !== undefined && (
+          {latestResult?.mortalityRate !== undefined && (
             <Typography fontSize='48px' fontWeight={600} lineHeight={1}>
               %
             </Typography>
           )}
         </Box>
-        {latestObservation?.mortalityRate === undefined && (
+        {latestResult?.mortalityRate === undefined && (
           <Box display={'flex'}>
             <Box paddingRight={0.5}>
               <Icon name='warning' fillColor={theme.palette.TwClrIcnWarning} size='medium' />
diff --git a/src/scenes/PlantsDashboardRouter/components/TotalMoratlityRateCard.tsx b/src/scenes/PlantsDashboardRouter/components/TotalMoratlityRateCard.tsx
index 4c1024fb2c94..6207a335b8cd 100644
--- a/src/scenes/PlantsDashboardRouter/components/TotalMoratlityRateCard.tsx
+++ b/src/scenes/PlantsDashboardRouter/components/TotalMoratlityRateCard.tsx
@@ -10,7 +10,7 @@ import { getShortDate } from 'src/utils/dateFormatter';
 export default function TotalMortalityRateCard(): JSX.Element {
   const theme = useTheme();
   const locale = useLocalization();
-  const { latestObservation } = usePlantingSiteData();
+  const { latestResult } = usePlantingSiteData();
 
   return (
     <OverviewItemCard
@@ -20,12 +20,12 @@ export default function TotalMortalityRateCard(): JSX.Element {
           <Typography fontSize='16px' fontWeight={600} marginBottom={theme.spacing(5)}>
             {strings.formatString(
               strings.MORTALITY_RATE_CARD_TITLE,
-              latestObservation?.completedTime ? getShortDate(latestObservation.completedTime, locale.activeLocale) : ''
+              latestResult?.completedTime ? getShortDate(latestResult.completedTime, locale.activeLocale) : ''
             )}
           </Typography>
           <Box display='flex' sx={{ flexFlow: 'row wrap' }}>
             <Typography fontSize='84px' fontWeight={600} lineHeight={1}>
-              {latestObservation?.mortalityRate ? <FormattedNumber value={latestObservation?.mortalityRate} /> : '--'}
+              {latestResult?.mortalityRate ? <FormattedNumber value={latestResult?.mortalityRate} /> : '--'}
             </Typography>
             <Typography fontSize='84px' fontWeight={600} lineHeight={1}>
               %
diff --git a/src/scenes/PlantsDashboardRouter/components/ZoneLevelDataMap.tsx b/src/scenes/PlantsDashboardRouter/components/ZoneLevelDataMap.tsx
index 7ab69dd6ace0..683137423c4a 100644
--- a/src/scenes/PlantsDashboardRouter/components/ZoneLevelDataMap.tsx
+++ b/src/scenes/PlantsDashboardRouter/components/ZoneLevelDataMap.tsx
@@ -18,7 +18,7 @@ type ZoneLevelDataMapProps = {
 export default function ZoneLevelDataMap({ plantingSiteId }: ZoneLevelDataMapProps): JSX.Element {
   const theme = useTheme();
 
-  const { plantingSite, plantingSiteHistories, plantingSiteReportedPlants, observationSummaries, latestObservation } =
+  const { plantingSite, plantingSiteHistories, plantingSiteReportedPlants, observationSummaries, latestResult } =
     usePlantingSiteData();
 
   const zonesProgress = useMemo(() => {
@@ -105,7 +105,7 @@ export default function ZoneLevelDataMap({ plantingSiteId }: ZoneLevelDataMapPro
         },
       ],
       switch: true,
-      disabled: !latestObservation,
+      disabled: !latestResult,
       checked: true,
     });
 
@@ -121,12 +121,12 @@ export default function ZoneLevelDataMap({ plantingSiteId }: ZoneLevelDataMapPro
         },
       ],
       switch: true,
-      disabled: !latestObservation,
+      disabled: !latestResult,
       checked: true,
     });
 
     setLegends(result);
-  }, [latestObservation, theme.palette.TwClrBaseGreen300, theme.palette.TwClrBaseLightGreen300]);
+  }, [latestResult, theme.palette.TwClrBaseGreen300, theme.palette.TwClrBaseLightGreen300]);
 
   const mapData = useMemo((): MapData | undefined => {
     if (!plantingSite?.boundary) {
@@ -134,12 +134,12 @@ export default function ZoneLevelDataMap({ plantingSiteId }: ZoneLevelDataMapPro
     }
 
     const baseMap = MapService.getMapDataFromPlantingSite(plantingSite);
-    if (!latestObservation?.plantingSiteHistoryId || !plantingSiteHistories) {
+    if (!latestResult?.plantingSiteHistoryId || !plantingSiteHistories) {
       return baseMap;
     }
 
     const plantingSiteHistory = plantingSiteHistories.find(
-      (history) => history.id === latestObservation.plantingSiteHistoryId
+      (history) => history.id === latestResult.plantingSiteHistoryId
     );
     if (!plantingSiteHistory) {
       return baseMap;
@@ -167,7 +167,7 @@ export default function ZoneLevelDataMap({ plantingSiteId }: ZoneLevelDataMapPro
         const entityZoneId = Number(entity.id);
         let properties: TooltipProperty[] = [];
 
-        const zoneObservation = latestObservation?.plantingZones.find(
+        const zoneObservation = latestResult?.plantingZones.find(
           (zoneResult) => zoneResult.plantingZoneId === entityZoneId
         );
         const zoneStat = zonesStats[entityZoneId];
@@ -240,7 +240,7 @@ export default function ZoneLevelDataMap({ plantingSiteId }: ZoneLevelDataMapPro
           />
         );
       },
-    [latestObservation, zonesProgress, zonesStats, lastSummary]
+    [latestResult, zonesProgress, zonesStats, lastSummary]
   );
 
   return (
@@ -263,9 +263,7 @@ export default function ZoneLevelDataMap({ plantingSiteId }: ZoneLevelDataMapPro
           mapData={mapData}
           style={{ borderRadius: '8px' }}
           layers={['Planting Site', 'Zones', 'Sub-Zones']}
-          showMortalityRateFill={
-            !!latestObservation && legends.find((l) => l.title === strings.MORTALITY_RATE)?.checked
-          }
+          showMortalityRateFill={!!latestResult && legends.find((l) => l.title === strings.MORTALITY_RATE)?.checked}
           showRecencyFill={legends.find((l) => l.title === strings.OBSERVATION_RECENCY)?.checked}
           focusEntities={focusEntities}
           contextRenderer={{
diff --git a/src/services/CohortService.ts b/src/services/CohortService.ts
index b1388dd1e247..4bc4aac991aa 100644
--- a/src/services/CohortService.ts
+++ b/src/services/CohortService.ts
@@ -26,8 +26,6 @@ const COHORT_ENDPOINT = '/api/v1/accelerator/cohorts/{cohortId}';
 
 export type ListCohortsResponsePayload =
   paths[typeof COHORTS_ENDPOINT]['get']['responses'][200]['content']['application/json'];
-export type ListCohortsRequestDepth = paths[typeof COHORTS_ENDPOINT]['get']['parameters']['query']['cohortDepth'];
-
 export type CreateCohortResponsePayload =
   paths[typeof COHORTS_ENDPOINT]['post']['responses'][200]['content']['application/json'];
 export type GetCohortResponsePayload =
@@ -47,8 +45,7 @@ const httpCohorts = HttpService.root(COHORTS_ENDPOINT);
 const listCohorts = async (
   locale: string | null,
   search?: SearchNodePayload,
-  searchSortOrder?: SearchSortOrder,
-  cohortDepth: ListCohortsRequestDepth = 'Cohort'
+  searchSortOrder?: SearchSortOrder
 ): Promise<(CohortsData & Response) | null> => {
   let searchOrderConfig: SearchOrderConfig;
   if (searchSortOrder) {
@@ -59,7 +56,7 @@ const listCohorts = async (
     };
   }
 
-  return httpCohorts.get<ListCohortsResponsePayload, CohortsData>({ params: { cohortDepth } }, (response) => {
+  return httpCohorts.get<ListCohortsResponsePayload, CohortsData>({}, (response) => {
     const cohorts = searchAndSort(response?.cohorts || [], search, searchOrderConfig);
     const newCohorts: CohortWithParticipantNum[] = cohorts.map((c) => ({
       ...c,
@@ -77,10 +74,9 @@ const createCohort = (cohort: CreateCohortRequestPayload): Promise<Response> =>
     entity: cohort,
   });
 
-const getCohort = (cohortId: number, cohortDepth: ListCohortsRequestDepth = 'Cohort'): Promise<Response2<Cohort>> =>
+const getCohort = (cohortId: number): Promise<Response2<Cohort>> =>
   httpCohort.get<GetCohortResponsePayload, { data: Cohort | undefined }>(
     {
-      params: { cohortDepth },
       url: COHORT_ENDPOINT,
       urlReplacements: { '{cohortId}': `${cohortId}` },
     },


Reviews:
user: login: graphite-app[bot]
state: COMMENTED
author_association: NONE
submitted_at: 2025-05-13T00:29:01Z
user: login: constanzauanini
state: COMMENTED
author_association: CONTRIBUTOR
submitted_at: 2025-05-13T12:21:21Z
user: login: tommylau523
state: COMMENTED
author_association: CONTRIBUTOR
submitted_at: 2025-05-13T18:30:32Z
user: login: tommylau523
state: COMMENTED
author_association: CONTRIBUTOR
submitted_at: 2025-05-13T18:30:55Z
user: login: constanzauanini
state: COMMENTED
author_association: CONTRIBUTOR
submitted_at: 2025-05-13T18:34:30Z
user: login: constanzauanini
state: COMMENTED
author_association: CONTRIBUTOR
submitted_at: 2025-05-14T12:53:50Z
user: login: constanzauanini
state: APPROVED
author_association: CONTRIBUTOR
submitted_at: 2025-05-14T12:54:05Z

Review comments:
diff_hunk: @@ -89,31 +89,31 @@ export default function PlantsDashboardView({ projectId, organizationId }: Plant
     </Grid>
   );
 
-  const getLatestObservationLink = useCallback(() => {
-    const allMonitoringPlots = latestObservation?.plantingZones.flatMap((pz) =>
+  const getlatestResultLink = useCallback(() => {
path: src/scenes/PlantsDashboardRouter/PlantsDashboardView.tsx
user: login: graphite-app[bot]
body: The function name `getlatestResultLink` doesn't follow JavaScript's camelCase naming convention. It should be renamed to `getLatestResultLink` to maintain consistency with the codebase's naming patterns and improve readability.
```suggestion
  const getLatestResultLink = useCallback(() => {
```
  

*Spotted by [Diamond](https://app.graphite.dev/diamond/?org=terraware&ref=ai-review-comment)*<i class='graphite__hidden'><br /><br />Is this helpful? React 👍 or 👎 to let us know.</i>
created_at: 2025-05-13T00:29:00Z
author_association: NONE
diff_hunk: @@ -182,6 +182,29 @@ const PlantingSiteProvider = ({ children }: Props) => {
     );
   }, [observationResults]);
 
+  const latestObservation = useMemo(() => {
path: src/providers/Tracking/PlantingSiteProvider.tsx
user: login: constanzauanini
body: Why is this latestObservation added here. Isn't it the same as latestResult?
created_at: 2025-05-13T12:21:21Z
author_association: CONTRIBUTOR
diff_hunk: @@ -182,6 +182,29 @@ const PlantingSiteProvider = ({ children }: Props) => {
     );
   }, [observationResults]);
 
+  const latestObservation = useMemo(() => {
path: src/providers/Tracking/PlantingSiteProvider.tsx
user: login: tommylau523
body: the observations and results have different payloads. they come from two different endpoints. results include plant count and statistics. observations include original end dates and such. 
created_at: 2025-05-13T18:30:32Z
author_association: CONTRIBUTOR
diff_hunk: @@ -182,6 +182,29 @@ const PlantingSiteProvider = ({ children }: Props) => {
     );
   }, [observationResults]);
 
+  const latestObservation = useMemo(() => {
path: src/providers/Tracking/PlantingSiteProvider.tsx
user: login: tommylau523
body: Most of our use cases will use results, but only seed fund reports, and the observations tables use observations. 
created_at: 2025-05-13T18:30:55Z
author_association: CONTRIBUTOR
diff_hunk: @@ -182,6 +182,29 @@ const PlantingSiteProvider = ({ children }: Props) => {
     );
   }, [observationResults]);
 
+  const latestObservation = useMemo(() => {
path: src/providers/Tracking/PlantingSiteProvider.tsx
user: login: constanzauanini
body: Thank you! I didn't realize this was using observations!
created_at: 2025-05-13T18:34:30Z
author_association: CONTRIBUTOR
diff_hunk: @@ -77,10 +74,10 @@ const createCohort = (cohort: CreateCohortRequestPayload): Promise<Response> =>
     entity: cohort,
   });
 
-const getCohort = (cohortId: number, cohortDepth: ListCohortsRequestDepth = 'Cohort'): Promise<Response2<Cohort>> =>
+const getCohort = (cohortId: number): Promise<Response2<Cohort>> =>
   httpCohort.get<GetCohortResponsePayload, { data: Cohort | undefined }>(
     {
-      params: { cohortDepth },
+      params: {},
path: src/services/CohortService.ts
user: login: constanzauanini
body: parms could be removed here
created_at: 2025-05-14T12:53:50Z
author_association: CONTRIBUTOR

PR comments:
user: login: vercel[bot]
created_at: 2025-05-13T00:15:40Z
body: [vc]: #5NCerl8+urWERDet5ikti6/QgunpTCdMs97RNhb04Rw=:eyJpc01vbm9yZXBvIjp0cnVlLCJ0eXBlIjoiZ2l0aHViIiwicHJvamVjdHMiOlt7Im5hbWUiOiJ0ZXJyYXdhcmUtd2ViLXN0b3J5Ym9vayIsInJvb3REaXJlY3RvcnkiOm51bGwsImluc3BlY3RvclVybCI6Imh0dHBzOi8vdmVyY2VsLmNvbS90ZXJyYWZvcm1hdGlvbi90ZXJyYXdhcmUtd2ViLXN0b3J5Ym9vay9FZ25zVzVLa0ZMOHVuWFgyRzNCREhyUnpSMnd2IiwicHJldmlld1VybCI6InRlcnJhd2FyZS13ZWItc3Rvcnlib29rLWdpdC10b21teWxhdS1yZW1vLWY4ZDNjMi10ZXJyYWZvcm1hdGlvbi52ZXJjZWwuYXBwIiwibmV4dENvbW1pdFN0YXR1cyI6IkRFUExPWUVEIiwibGl2ZUZlZWRiYWNrIjp7InJlc29sdmVkIjowLCJ1bnJlc29sdmVkIjowLCJ0b3RhbCI6MCwibGluayI6InRlcnJhd2FyZS13ZWItc3Rvcnlib29rLWdpdC10b21teWxhdS1yZW1vLWY4ZDNjMi10ZXJyYWZvcm1hdGlvbi52ZXJjZWwuYXBwIn19LHsibmFtZSI6InRyZWUtbG9jYXRpb24td2ViIiwicm9vdERpcmVjdG9yeSI6bnVsbCwiaW5zcGVjdG9yVXJsIjoiaHR0cHM6Ly92ZXJjZWwuY29tL3RlcnJhZm9ybWF0aW9uL3RyZWUtbG9jYXRpb24td2ViLzRVcUpnWG9MV3ZkREVnZURNM1VDWHdKUWhTOWQiLCJwcmV2aWV3VXJsIjoidHJlZS1sb2NhdGlvbi13ZWItZ2l0LXRvbW15bGF1LXJlbW92ZS1vYnMtZmQ0NTg5LXRlcnJhZm9ybWF0aW9uLnZlcmNlbC5hcHAiLCJuZXh0Q29tbWl0U3RhdHVzIjoiREVQTE9ZRUQiLCJsaXZlRmVlZGJhY2siOnsicmVzb2x2ZWQiOjAsInVucmVzb2x2ZWQiOjAsInRvdGFsIjowLCJsaW5rIjoidHJlZS1sb2NhdGlvbi13ZWItZ2l0LXRvbW15bGF1LXJlbW92ZS1vYnMtZmQ0NTg5LXRlcnJhZm9ybWF0aW9uLnZlcmNlbC5hcHAifX1dfQ==
**The latest updates on your projects**. Learn more about [Vercel for Git ↗︎](https://vercel.link/github-learn-more)

| Name | Status | Preview | Comments | Updated (UTC) |
| :--- | :----- | :------ | :------- | :------ |
| **terraware-web-storybook** | ✅ Ready ([Inspect](https://vercel.com/terraformation/terraware-web-storybook/EgnsW5KkFL8unXX2G3BDHrRzR2wv)) | [Visit Preview](https://terraware-web-storybook-git-tommylau-remo-f8d3c2-terraformation.vercel.app) | 💬 [**Add feedback**](https://vercel.live/open-feedback/terraware-web-storybook-git-tommylau-remo-f8d3c2-terraformation.vercel.app?via=pr-comment-feedback-link) | May 14, 2025 6:38pm |
| **tree-location-web** | ✅ Ready ([Inspect](https://vercel.com/terraformation/tree-location-web/4UqJgXoLWvdDEgeDM3UCXwJQhS9d)) | [Visit Preview](https://tree-location-web-git-tommylau-remove-obs-fd4589-terraformation.vercel.app) | 💬 [**Add feedback**](https://vercel.live/open-feedback/tree-location-web-git-tommylau-remove-obs-fd4589-terraformation.vercel.app?via=pr-comment-feedback-link) | May 14, 2025 6:38pm |



author_association: NONE
user: login: tommylau523
created_at: 2025-05-13T00:15:52Z
body: * **#3985** <a href="https://app.graphite.dev/github/pr/terraware/terraware-web/3985?utm_source=stack-comment-icon" target="_blank"><img src="https://static.graphite.dev/graphite-32x32-black.png" alt="Graphite" width="10px" height="10px"/></a> 👈 <a href="https://app.graphite.dev/github/pr/terraware/terraware-web/3985?utm_source=stack-comment-view-in-graphite" target="_blank">(View in Graphite)</a>
* `main`


<h2></h2>

This stack of pull requests is managed by <a href="https://graphite.dev?utm-source=stack-comment"><b>Graphite</b></a>. Learn more about <a href="https://stacking.dev/?utm_source=stack-comment">stacking</a>.
<!-- Current dependencies on/for this PR: -->
author_association: CONTRIBUTOR
user: login: tommylau523
created_at: 2025-05-14T18:45:25Z
body: ### Merge activity

* **May 14, 2:45 PM EDT**: @tommylau523 merged this pull request with [Graphite](https://app.graphite.dev/github/pr/terraware/terraware-web/3985).

author_association: CONTRIBUTOR