From 6310cdd04e53be930e70f10970f285bcd49cb261 Mon Sep 17 00:00:00 2001 From: Tyler Adam Martinez Date: Mon, 30 Mar 2026 12:42:03 -0500 Subject: [PATCH 1/7] fix(Equipment): Patch the UI grid on screen larger than sm --- src/components/WellShow/Equipment.tsx | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/src/components/WellShow/Equipment.tsx b/src/components/WellShow/Equipment.tsx index 02915b39..190ed5d1 100644 --- a/src/components/WellShow/Equipment.tsx +++ b/src/components/WellShow/Equipment.tsx @@ -114,10 +114,7 @@ export const EquipmentAccordion = ({ ( Date: Mon, 30 Mar 2026 13:09:17 -0500 Subject: [PATCH 2/7] feat(InteractiveSatelliteMap): Add Directions to the site --- .../card/InteractiveSatelliteMap.tsx | 37 +++++++++++++++++++ 1 file changed, 37 insertions(+) diff --git a/src/components/card/InteractiveSatelliteMap.tsx b/src/components/card/InteractiveSatelliteMap.tsx index bd197a08..ac54ff68 100644 --- a/src/components/card/InteractiveSatelliteMap.tsx +++ b/src/components/card/InteractiveSatelliteMap.tsx @@ -7,6 +7,7 @@ import { CardContent, CardHeader, Skeleton, + Typography, } from '@mui/material' import { Directions, Map } from '@mui/icons-material' import { Layer, MapRef, Source } from 'react-map-gl' @@ -144,6 +145,10 @@ export const InteractiveSatelliteMapCard = ({ well }: { well: IWell }) => { ? `https://www.google.com/maps/dir/?api=1&destination=${lat},${lon}` : null + const locationNote = well.current_location?.properties?.notes + ?.filter((note) => note.note_type === 'General') + .shift() + return ( { )} + {locationNote && ( + <> + + Directions to the site + + + {locationNote?.content} + + + )} ) @@ -234,8 +254,10 @@ const LoadingCard = () => { { height={MAP_HEIGHT} sx={{ borderRadius: '0.5rem' }} /> + + ) From 83dd906fc74c18f69bc126c89607a5656e19cd56 Mon Sep 17 00:00:00 2001 From: Tyler Adam Martinez Date: Mon, 30 Mar 2026 13:18:40 -0500 Subject: [PATCH 3/7] feat(WellPhysicalProperties): Add Measuring point description --- .../WellShow/WellPhysicalProperties.tsx | 106 ++++++++++-------- 1 file changed, 57 insertions(+), 49 deletions(-) diff --git a/src/components/WellShow/WellPhysicalProperties.tsx b/src/components/WellShow/WellPhysicalProperties.tsx index 2a460f4e..8f7e9f34 100644 --- a/src/components/WellShow/WellPhysicalProperties.tsx +++ b/src/components/WellShow/WellPhysicalProperties.tsx @@ -10,55 +10,63 @@ export const WellPhysicalPropertiesAccordion = ({ well }: { well?: IWell }) => { - - - - Casing Diameter: - - - {well?.well_casing_diameter?.toFixed(2) || 'N/A'} - {well?.well_casing_diameter - ? ` ${well?.well_casing_diameter_unit}` - : null} - - - - - Casing Depth: - - - {well?.well_casing_depth?.toFixed(2) || 'N/A'} - {well?.well_casing_depth - ? ` ${well?.well_casing_depth_unit}` - : null} - - - - - Casing Materials: - - - {well?.well_casing_materials?.join(', ') || 'N/A'} - - - - - Pump Type: - - - {well?.well_pump_type || 'N/A'} - - - - - Pump Depth: - - - {well?.well_pump_depth?.toFixed(2) || 'N/A'} - {well?.well_pump_depth ? ` ${well?.well_pump_depth_unit}` : null} - - - + + + + Casing Diameter: + + + {well?.well_casing_diameter?.toFixed(2) || 'N/A'} + {well?.well_casing_diameter + ? ` ${well?.well_casing_diameter_unit}` + : null} + + + + + Casing Depth: + + + {well?.well_casing_depth?.toFixed(2) || 'N/A'} + {well?.well_casing_depth + ? ` ${well?.well_casing_depth_unit}` + : null} + + + + + Casing Materials: + + + {well?.well_casing_materials?.join(', ') || 'N/A'} + + + + + Pump Type: + + + {well?.well_pump_type || 'N/A'} + + + + + Pump Depth: + + + {well?.well_pump_depth?.toFixed(2) || 'N/A'} + {well?.well_pump_depth ? ` ${well?.well_pump_depth_unit}` : null} + + + + + Measuring Point: + + + {well?.measuring_point_description || 'N/A'} + + + ) From f23b50285dbba4b379475b54ccdadf11373f65d2 Mon Sep 17 00:00:00 2001 From: Tyler Adam Martinez Date: Mon, 30 Mar 2026 13:31:20 -0500 Subject: [PATCH 4/7] feat(RecentWaterLevelObservations): Add measuring note --- .../card/RecentWaterLevelObservations.tsx | 29 +++++++++++++++++-- src/pages/ocotillo/thing/well-show.tsx | 11 ++----- 2 files changed, 29 insertions(+), 11 deletions(-) diff --git a/src/components/card/RecentWaterLevelObservations.tsx b/src/components/card/RecentWaterLevelObservations.tsx index c27c1513..98088e30 100644 --- a/src/components/card/RecentWaterLevelObservations.tsx +++ b/src/components/card/RecentWaterLevelObservations.tsx @@ -46,8 +46,15 @@ export const RecentWaterLevelObservationsCard = ({ ] }, []) + const measuringNote = well.general_notes + .filter((note) => note.note_type === 'General') + .shift() + return ( - + @@ -96,6 +103,21 @@ export const RecentWaterLevelObservationsCard = ({ }} /> )} + {measuringNote && ( + <> + + Measurement Note + + + {measuringNote?.content} + + + )} ) @@ -103,7 +125,10 @@ export const RecentWaterLevelObservationsCard = ({ const LoadingCard = () => { return ( - + diff --git a/src/pages/ocotillo/thing/well-show.tsx b/src/pages/ocotillo/thing/well-show.tsx index 56bbbae9..64ba8579 100644 --- a/src/pages/ocotillo/thing/well-show.tsx +++ b/src/pages/ocotillo/thing/well-show.tsx @@ -1,9 +1,5 @@ import { useMemo } from 'react' -import { - useDataProvider, - useList, - useResourceParams, -} from '@refinedev/core' +import { useDataProvider, useList, useResourceParams } from '@refinedev/core' import { useQuery } from '@tanstack/react-query' import { Show, useDataGrid } from '@refinedev/mui' import { AppBreadcrumb } from '@/components/AppBreadcrumb' @@ -308,10 +304,7 @@ export const WellShow = () => { {/* Right column: 2 cols */} - + From f4120ed81486c4b533d8bf7345da9341b947dbd6 Mon Sep 17 00:00:00 2001 From: Tyler Adam Martinez Date: Tue, 31 Mar 2026 09:20:46 -0500 Subject: [PATCH 5/7] revert(WellPhysicalProperties): Undo changes --- .../WellShow/WellPhysicalProperties.tsx | 106 ++++++++---------- 1 file changed, 49 insertions(+), 57 deletions(-) diff --git a/src/components/WellShow/WellPhysicalProperties.tsx b/src/components/WellShow/WellPhysicalProperties.tsx index 8f7e9f34..2a460f4e 100644 --- a/src/components/WellShow/WellPhysicalProperties.tsx +++ b/src/components/WellShow/WellPhysicalProperties.tsx @@ -10,63 +10,55 @@ export const WellPhysicalPropertiesAccordion = ({ well }: { well?: IWell }) => { - - - - Casing Diameter: - - - {well?.well_casing_diameter?.toFixed(2) || 'N/A'} - {well?.well_casing_diameter - ? ` ${well?.well_casing_diameter_unit}` - : null} - - - - - Casing Depth: - - - {well?.well_casing_depth?.toFixed(2) || 'N/A'} - {well?.well_casing_depth - ? ` ${well?.well_casing_depth_unit}` - : null} - - - - - Casing Materials: - - - {well?.well_casing_materials?.join(', ') || 'N/A'} - - - - - Pump Type: - - - {well?.well_pump_type || 'N/A'} - - - - - Pump Depth: - - - {well?.well_pump_depth?.toFixed(2) || 'N/A'} - {well?.well_pump_depth ? ` ${well?.well_pump_depth_unit}` : null} - - - - - Measuring Point: - - - {well?.measuring_point_description || 'N/A'} - - - + + + + Casing Diameter: + + + {well?.well_casing_diameter?.toFixed(2) || 'N/A'} + {well?.well_casing_diameter + ? ` ${well?.well_casing_diameter_unit}` + : null} + + + + + Casing Depth: + + + {well?.well_casing_depth?.toFixed(2) || 'N/A'} + {well?.well_casing_depth + ? ` ${well?.well_casing_depth_unit}` + : null} + + + + + Casing Materials: + + + {well?.well_casing_materials?.join(', ') || 'N/A'} + + + + + Pump Type: + + + {well?.well_pump_type || 'N/A'} + + + + + Pump Depth: + + + {well?.well_pump_depth?.toFixed(2) || 'N/A'} + {well?.well_pump_depth ? ` ${well?.well_pump_depth_unit}` : null} + + + ) From dc84dcb9c3cdbc50b4e123af3e1398f5055a552c Mon Sep 17 00:00:00 2001 From: Tyler Adam Martinez Date: Tue, 31 Mar 2026 09:30:35 -0500 Subject: [PATCH 6/7] refactor(Notes): Remove direction to site note from section --- src/components/WellShow/Notes.tsx | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/src/components/WellShow/Notes.tsx b/src/components/WellShow/Notes.tsx index 793549e0..4a1de567 100644 --- a/src/components/WellShow/Notes.tsx +++ b/src/components/WellShow/Notes.tsx @@ -1,16 +1,24 @@ -import { Box, Paper, Stack, Typography } from '@mui/material' +import { Box, Paper, Typography } from '@mui/material' import { Notes } from '@mui/icons-material' import Grid from '@mui/material/Grid2' import { IWell } from '@/interfaces/ocotillo' import { groupNotesByType } from '@/utils' export const NotesAccordion = ({ well }: { well?: IWell }) => { + const locationNote = well?.current_location?.properties?.notes + ?.filter((note) => note.note_type === 'General') + .shift() + const allNotes = [ ...(well?.water_notes ?? []), ...(well?.measuring_notes ?? []), ...(well?.construction_notes ?? []), ...(well?.general_notes ?? []), - ...(well?.current_location?.properties?.notes ?? []), + // Exclude the specific location "General" note used in the map ("Directions to the site"). + // This prevents duplicate content between the map and Notes section. + ...(well?.current_location?.properties?.notes ?? []).filter( + (note) => note.id !== locationNote?.id + ), ...(well?.sampling_procedure_notes ?? []), ] @@ -24,7 +32,9 @@ export const NotesAccordion = ({ well }: { well?: IWell }) => { return ( - + Notes From d56611bd8c97443e55d2797fafd4683db1bc7368 Mon Sep 17 00:00:00 2001 From: Tyler Adam Martinez Date: Tue, 31 Mar 2026 11:34:53 -0500 Subject: [PATCH 7/7] fix(RecentWaterLevelObservations): patch mesuring notes logic --- src/components/card/RecentWaterLevelObservations.tsx | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/components/card/RecentWaterLevelObservations.tsx b/src/components/card/RecentWaterLevelObservations.tsx index 98088e30..7d31912a 100644 --- a/src/components/card/RecentWaterLevelObservations.tsx +++ b/src/components/card/RecentWaterLevelObservations.tsx @@ -46,9 +46,7 @@ export const RecentWaterLevelObservationsCard = ({ ] }, []) - const measuringNote = well.general_notes - .filter((note) => note.note_type === 'General') - .shift() + const measuringNote = well?.measuring_notes?.shift() return (