@@ -10,6 +10,7 @@ import React, { useMemo } from "react";
|
|||||||
import { useTranslation } from "react-i18next";
|
import { useTranslation } from "react-i18next";
|
||||||
import { Link } from "react-router-dom";
|
import { Link } from "react-router-dom";
|
||||||
import { DateTimeFormatter } from "../../utils/DateFormatter";
|
import { DateTimeFormatter } from "../../utils/DateFormatter";
|
||||||
|
import Dinero from "dinero.js";
|
||||||
|
|
||||||
import ProductionAlert from "../production-list-columns/production-list-columns.alert.component";
|
import ProductionAlert from "../production-list-columns/production-list-columns.alert.component";
|
||||||
import ProductionListColumnProductionNote from "../production-list-columns/production-list-columns.productionnote.component";
|
import ProductionListColumnProductionNote from "../production-list-columns/production-list-columns.productionnote.component";
|
||||||
@@ -192,6 +193,47 @@ const ActualInToolTip = ({ metadata, cardSettings }) =>
|
|||||||
</Col>
|
</Col>
|
||||||
);
|
);
|
||||||
|
|
||||||
|
const EstimatorToolTip = ({ metadata, cardSettings }) => {
|
||||||
|
return (
|
||||||
|
cardSettings?.estimator && (
|
||||||
|
<Col span={cardSettings.compact ? 24 : 12}>
|
||||||
|
<EllipsesToolTip
|
||||||
|
title={metadata.est_ct_fn && metadata.est_ct_ln ? `${metadata.est_ct_fn} ${metadata.est_ct_ln}` : null}
|
||||||
|
kiosk={cardSettings.kiosk}
|
||||||
|
>
|
||||||
|
{metadata.est_ct_fn && metadata.est_ct_ln ? (
|
||||||
|
<span>E: {`${metadata.est_ct_fn} ${metadata.est_ct_ln}`}</span>
|
||||||
|
) : (
|
||||||
|
<span> </span>
|
||||||
|
)}
|
||||||
|
</EllipsesToolTip>
|
||||||
|
</Col>
|
||||||
|
)
|
||||||
|
);
|
||||||
|
};
|
||||||
|
|
||||||
|
const SubtotalTooltip = ({ metadata, cardSettings, t }) => {
|
||||||
|
const amount = metadata?.job_totals?.totals?.subtotal?.amount;
|
||||||
|
const dineroAmount = amount ? Dinero({ amount: parseInt(amount * 100) }).toFormat("0,0.00") : null;
|
||||||
|
|
||||||
|
return (
|
||||||
|
cardSettings?.subtotal && (
|
||||||
|
<Col span={cardSettings.compact ? 24 : 12}>
|
||||||
|
<EllipsesToolTip
|
||||||
|
title={!!amount ? `${t("production.statistics.currency_symbol")}${dineroAmount}` : null}
|
||||||
|
kiosk={cardSettings.kiosk}
|
||||||
|
>
|
||||||
|
{!!amount ? (
|
||||||
|
<span>{`${t("production.statistics.currency_symbol")}${dineroAmount}`}</span>
|
||||||
|
) : (
|
||||||
|
<span> </span>
|
||||||
|
)}
|
||||||
|
</EllipsesToolTip>
|
||||||
|
</Col>
|
||||||
|
)
|
||||||
|
);
|
||||||
|
};
|
||||||
|
|
||||||
const ScheduledCompletionToolTip = ({ metadata, cardSettings, pastDueAlert }) =>
|
const ScheduledCompletionToolTip = ({ metadata, cardSettings, pastDueAlert }) =>
|
||||||
cardSettings?.scheduled_completion && (
|
cardSettings?.scheduled_completion && (
|
||||||
<Col span={cardSettings.compact ? 24 : 12}>
|
<Col span={cardSettings.compact ? 24 : 12}>
|
||||||
@@ -292,7 +334,9 @@ export default function ProductionBoardCard({ technician, card, bodyshop, cardSe
|
|||||||
cardSettings?.ats ||
|
cardSettings?.ats ||
|
||||||
cardSettings?.sublets ||
|
cardSettings?.sublets ||
|
||||||
cardSettings?.production_note ||
|
cardSettings?.production_note ||
|
||||||
cardSettings?.partsstatus
|
cardSettings?.partsstatus ||
|
||||||
|
cardSettings?.estimator ||
|
||||||
|
cardSettings?.subtotal
|
||||||
);
|
);
|
||||||
}, [cardSettings]);
|
}, [cardSettings]);
|
||||||
|
|
||||||
@@ -348,6 +392,8 @@ export default function ProductionBoardCard({ technician, card, bodyshop, cardSe
|
|||||||
employee_refinish={employee_refinish}
|
employee_refinish={employee_refinish}
|
||||||
employee_csr={employee_csr}
|
employee_csr={employee_csr}
|
||||||
/>
|
/>
|
||||||
|
<EstimatorToolTip metadata={metadata} cardSettings={cardSettings} />
|
||||||
|
<SubtotalTooltip metadata={metadata} cardSettings={cardSettings} t={t} />
|
||||||
<ActualInToolTip metadata={metadata} cardSettings={cardSettings} />
|
<ActualInToolTip metadata={metadata} cardSettings={cardSettings} />
|
||||||
<ScheduledCompletionToolTip metadata={metadata} cardSettings={cardSettings} pastDueAlert={pastDueAlert} />
|
<ScheduledCompletionToolTip metadata={metadata} cardSettings={cardSettings} pastDueAlert={pastDueAlert} />
|
||||||
<AltTransportToolTip metadata={metadata} cardSettings={cardSettings} />
|
<AltTransportToolTip metadata={metadata} cardSettings={cardSettings} />
|
||||||
|
|||||||
@@ -16,7 +16,9 @@ const InformationSettings = ({ t }) => (
|
|||||||
"ats",
|
"ats",
|
||||||
"production_note",
|
"production_note",
|
||||||
"sublets",
|
"sublets",
|
||||||
"partsstatus"
|
"partsstatus",
|
||||||
|
"estimator",
|
||||||
|
"subtotal"
|
||||||
].map((item) => (
|
].map((item) => (
|
||||||
<Col span={4} key={item}>
|
<Col span={4} key={item}>
|
||||||
<Form.Item name={item} valuePropName="checked">
|
<Form.Item name={item} valuePropName="checked">
|
||||||
|
|||||||
@@ -17,7 +17,7 @@ const StatisticsSettings = ({ t, statisticsOrder, setStatisticsOrder, setHasChan
|
|||||||
return (
|
return (
|
||||||
<Card title={t("production.settings.statistics_title")}>
|
<Card title={t("production.settings.statistics_title")}>
|
||||||
<DragDropContext onDragEnd={onDragEnd}>
|
<DragDropContext onDragEnd={onDragEnd}>
|
||||||
<Droppable direction="horizontal" droppableId="statistics">
|
<Droppable direction="grid" droppableId="statistics">
|
||||||
{(provided) => (
|
{(provided) => (
|
||||||
<div
|
<div
|
||||||
{...provided.droppableProps}
|
{...provided.droppableProps}
|
||||||
|
|||||||
@@ -36,6 +36,8 @@ const defaultKanbanSettings = {
|
|||||||
totalLAROnBoard: false,
|
totalLAROnBoard: false,
|
||||||
jobsOnBoard: false,
|
jobsOnBoard: false,
|
||||||
totalAmountOnBoard: true,
|
totalAmountOnBoard: true,
|
||||||
|
estimator: false,
|
||||||
|
subtotal: false,
|
||||||
statisticsOrder: statisticsItems.map((item) => item.id),
|
statisticsOrder: statisticsItems.map((item) => item.id),
|
||||||
selectedMdInsCos: [],
|
selectedMdInsCos: [],
|
||||||
selectedEstimators: []
|
selectedEstimators: []
|
||||||
|
|||||||
@@ -2813,6 +2813,8 @@
|
|||||||
"ownr_nm": "Customer Name",
|
"ownr_nm": "Customer Name",
|
||||||
"paintpriority": "P/P",
|
"paintpriority": "P/P",
|
||||||
"partsstatus": "Parts Status",
|
"partsstatus": "Parts Status",
|
||||||
|
"estimator": "Estimator",
|
||||||
|
"subtotal": "Subtotal",
|
||||||
"production_note": "Production Note",
|
"production_note": "Production Note",
|
||||||
"refinishhours": "R",
|
"refinishhours": "R",
|
||||||
"scheduled_completion": "Scheduled Completion",
|
"scheduled_completion": "Scheduled Completion",
|
||||||
|
|||||||
@@ -2813,6 +2813,8 @@
|
|||||||
"ownr_nm": "",
|
"ownr_nm": "",
|
||||||
"paintpriority": "",
|
"paintpriority": "",
|
||||||
"partsstatus": "",
|
"partsstatus": "",
|
||||||
|
"estimator": "",
|
||||||
|
"subtotal": "",
|
||||||
"production_note": "",
|
"production_note": "",
|
||||||
"refinishhours": "",
|
"refinishhours": "",
|
||||||
"scheduled_completion": "",
|
"scheduled_completion": "",
|
||||||
|
|||||||
@@ -2813,6 +2813,8 @@
|
|||||||
"ownr_nm": "",
|
"ownr_nm": "",
|
||||||
"paintpriority": "",
|
"paintpriority": "",
|
||||||
"partsstatus": "",
|
"partsstatus": "",
|
||||||
|
"estimator": "",
|
||||||
|
"subtotal": "",
|
||||||
"production_note": "",
|
"production_note": "",
|
||||||
"refinishhours": "",
|
"refinishhours": "",
|
||||||
"scheduled_completion": "",
|
"scheduled_completion": "",
|
||||||
|
|||||||
Reference in New Issue
Block a user