Add extra spacing in Infra Work details.
This commit is contained in:
parent
3f4b7d08d4
commit
7455d8a221
@ -14,7 +14,7 @@ import {
|
|||||||
} from "../../../utils/constants";
|
} from "../../../utils/constants";
|
||||||
import { useParams } from "react-router-dom";
|
import { useParams } from "react-router-dom";
|
||||||
import ProgressBar from "../../common/ProgressBar";
|
import ProgressBar from "../../common/ProgressBar";
|
||||||
import {formatNumber} from "../../../utils/dateUtils";
|
import { formatNumber } from "../../../utils/dateUtils";
|
||||||
import { useServices } from "../../../hooks/masterHook/useMaster";
|
import { useServices } from "../../../hooks/masterHook/useMaster";
|
||||||
|
|
||||||
const WorkArea = ({ workArea, floor, forBuilding }) => {
|
const WorkArea = ({ workArea, floor, forBuilding }) => {
|
||||||
@ -27,7 +27,7 @@ const WorkArea = ({ workArea, floor, forBuilding }) => {
|
|||||||
|
|
||||||
const ManageInfra = useHasUserPermission(MANAGE_PROJECT_INFRA);
|
const ManageInfra = useHasUserPermission(MANAGE_PROJECT_INFRA);
|
||||||
const ManageAndAssignTak = useHasUserPermission(ASSIGN_REPORT_TASK);
|
const ManageAndAssignTak = useHasUserPermission(ASSIGN_REPORT_TASK);
|
||||||
const { ProjectTaskList, isLoading } = useProjectTasks(workArea.id,selectedService, IsExpandedArea);
|
const { ProjectTaskList, isLoading } = useProjectTasks(workArea.id, selectedService, IsExpandedArea);
|
||||||
|
|
||||||
const [workAreaStatus, setWorkAreaStatus] = useState({
|
const [workAreaStatus, setWorkAreaStatus] = useState({
|
||||||
completed: 0,
|
completed: 0,
|
||||||
@ -82,8 +82,7 @@ const WorkArea = ({ workArea, floor, forBuilding }) => {
|
|||||||
aria-controls={`collapse-${workArea.id}`}
|
aria-controls={`collapse-${workArea.id}`}
|
||||||
>
|
>
|
||||||
<i
|
<i
|
||||||
className={`bx me-2 toggle-icon ${
|
className={`bx me-2 toggle-icon ${IsExpandedArea ? "bx-minus-circle" : "bx-plus-circle"
|
||||||
IsExpandedArea ? "bx-minus-circle" : "bx-plus-circle"
|
|
||||||
}`}
|
}`}
|
||||||
style={{
|
style={{
|
||||||
fontSize: "1.2rem",
|
fontSize: "1.2rem",
|
||||||
@ -109,7 +108,7 @@ const WorkArea = ({ workArea, floor, forBuilding }) => {
|
|||||||
<ProgressBar
|
<ProgressBar
|
||||||
completedWork={formatNumber(workArea?.completedWork)}
|
completedWork={formatNumber(workArea?.completedWork)}
|
||||||
plannedWork={formatNumber(workArea?.plannedWork)}
|
plannedWork={formatNumber(workArea?.plannedWork)}
|
||||||
className="m-0 text-info"
|
className="m-0 my-2 me-6 text-info"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -121,12 +120,12 @@ const WorkArea = ({ workArea, floor, forBuilding }) => {
|
|||||||
className="accordion-collapse collapse"
|
className="accordion-collapse collapse"
|
||||||
aria-labelledby={`heading-${workArea.id}`}
|
aria-labelledby={`heading-${workArea.id}`}
|
||||||
>
|
>
|
||||||
<div className="accordion-body px-1">
|
<div className="accordion-body px-6">
|
||||||
{isLoading || ProjectTaskList === undefined ? (
|
{isLoading || ProjectTaskList === undefined ? (
|
||||||
<div className="text-center py-2 text-muted">Loading activities...</div>
|
<div className="text-center py-2 text-muted">Loading activities...</div>
|
||||||
) : ProjectTaskList?.length === 0 ? (
|
) : ProjectTaskList?.length === 0 ? (
|
||||||
<div className="text-center py-2 text-muted">No activities available for this work area.</div>
|
<div className="text-center py-2 text-muted">No activities available for this work area.</div>
|
||||||
):ProjectTaskList?.length > 0 ? (
|
) : ProjectTaskList?.length > 0 ? (
|
||||||
<table className="table table-sm mx-1">
|
<table className="table table-sm mx-1">
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
@ -152,7 +151,7 @@ const WorkArea = ({ workArea, floor, forBuilding }) => {
|
|||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
<tbody className="table-border-bottom-0">
|
<tbody className="table-border-bottom-0">
|
||||||
{ProjectTaskList.map((workItem,index) => (
|
{ProjectTaskList.map((workItem, index) => (
|
||||||
<WorkItem
|
<WorkItem
|
||||||
key={workItem.workItemId || `fallback-${index}`}
|
key={workItem.workItemId || `fallback-${index}`}
|
||||||
workItem={workItem}
|
workItem={workItem}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user