From 48f013edd592bd48fcff905741d5931d0717afb5 Mon Sep 17 00:00:00 2001 From: "kartik.sharma" Date: Sat, 17 May 2025 14:45:35 +0530 Subject: [PATCH] On the Infrastructure tab, the Planned and Completed columns have been merged, and their data is now shown as '2/3'. --- .../Project/Infrastructure/WorkArea.jsx | 3 -- .../Project/Infrastructure/WorkItem.jsx | 36 ++++++++----------- 2 files changed, 15 insertions(+), 24 deletions(-) diff --git a/src/components/Project/Infrastructure/WorkArea.jsx b/src/components/Project/Infrastructure/WorkArea.jsx index 05f16089..cbe34dc5 100644 --- a/src/components/Project/Infrastructure/WorkArea.jsx +++ b/src/components/Project/Infrastructure/WorkArea.jsx @@ -186,9 +186,6 @@ const WorkArea = ({ workArea, floor, forBuilding }) => { Completed/Planned - - Today's Planned - Progress diff --git a/src/components/Project/Infrastructure/WorkItem.jsx b/src/components/Project/Infrastructure/WorkItem.jsx index 6cf17687..9a694729 100644 --- a/src/components/Project/Infrastructure/WorkItem.jsx +++ b/src/components/Project/Infrastructure/WorkItem.jsx @@ -148,7 +148,7 @@ const WorkItem = ({ {hasWorkItem ? NewWorkItem?.workItem?.activityMaster?.activityName || - workItem.activityMaster?.activityName + workItem.activityMaster?.activityName : "NA"} @@ -157,8 +157,8 @@ const WorkItem = ({ {hasWorkItem ? NewWorkItem?.workItem?.completedWork ?? - workItem?.completedWork ?? - "NA" + workItem?.completedWork ?? + "NA" : "NA"} /{" "} {hasWorkItem @@ -171,28 +171,22 @@ const WorkItem = ({ {hasWorkItem ? NewWorkItem?.workItem?.workCategoryMaster?.name || - workItem.workCategoryMaster?.name || - "NA" + workItem.workCategoryMaster?.name || + "NA" : "NA"} - {/* Planned - visible on medium and above */} - {hasWorkItem - ? NewWorkItem?.workItem?.plannedWork ?? - workItem?.plannedWork ?? - "NA" - : "NA"} - - - {/* Completed - visible on medium and above */} - - {hasWorkItem - ? NewWorkItem?.workItem?.completedWork ?? - workItem?.completedWork ?? - "NA" - : "NA"} + {hasWorkItem ? ( + `${NewWorkItem?.workItem?.completedWork ?? + workItem?.completedWork ?? + "0"}/${NewWorkItem?.workItem?.plannedWork ?? + workItem?.plannedWork ?? + "0"}` + ) : ( + "NA" + )} {/* Progress Bar - always visible */} @@ -205,7 +199,7 @@ const WorkItem = ({ width: getProgress( NewWorkItem?.workItem?.plannedWork || workItem?.plannedWork, NewWorkItem?.workItem?.completedWork || - workItem?.completedWork + workItem?.completedWork ), height: "5px", }}