@@ -1,4 +1,4 @@
|
||||
<babeledit_project version="1.2" be_version="2.7.1">
|
||||
<babeledit_project be_version="2.7.1" version="1.2">
|
||||
<!--
|
||||
|
||||
BabelEdit project file
|
||||
@@ -20437,6 +20437,48 @@
|
||||
</translation>
|
||||
</translations>
|
||||
</concept_node>
|
||||
<concept_node>
|
||||
<name>calc_repair_days</name>
|
||||
<definition_loaded>false</definition_loaded>
|
||||
<description></description>
|
||||
<comment></comment>
|
||||
<default_text></default_text>
|
||||
<translations>
|
||||
<translation>
|
||||
<language>en-US</language>
|
||||
<approved>false</approved>
|
||||
</translation>
|
||||
<translation>
|
||||
<language>es-MX</language>
|
||||
<approved>false</approved>
|
||||
</translation>
|
||||
<translation>
|
||||
<language>fr-CA</language>
|
||||
<approved>false</approved>
|
||||
</translation>
|
||||
</translations>
|
||||
</concept_node>
|
||||
<concept_node>
|
||||
<name>calc_repair_days_tt</name>
|
||||
<definition_loaded>false</definition_loaded>
|
||||
<description></description>
|
||||
<comment></comment>
|
||||
<default_text></default_text>
|
||||
<translations>
|
||||
<translation>
|
||||
<language>en-US</language>
|
||||
<approved>false</approved>
|
||||
</translation>
|
||||
<translation>
|
||||
<language>es-MX</language>
|
||||
<approved>false</approved>
|
||||
</translation>
|
||||
<translation>
|
||||
<language>fr-CA</language>
|
||||
<approved>false</approved>
|
||||
</translation>
|
||||
</translations>
|
||||
</concept_node>
|
||||
<folder_node>
|
||||
<name>cards</name>
|
||||
<children>
|
||||
|
||||
@@ -313,9 +313,12 @@ export function JobLinesComponent({
|
||||
if (e.key === "clear") {
|
||||
setSelectedLines([]);
|
||||
} else {
|
||||
const markedTypes = [e.key];
|
||||
if (e.key === "PAN") markedTypes.push("PAP");
|
||||
if (e.key === "PAS") markedTypes.push("PASL");
|
||||
setSelectedLines([
|
||||
...selectedLines,
|
||||
...jobLines.filter((item) => item.part_type === e.key),
|
||||
...jobLines.filter((item) => markedTypes.includes(item.part_type)),
|
||||
]);
|
||||
}
|
||||
};
|
||||
@@ -378,7 +381,7 @@ export function JobLinesComponent({
|
||||
setState({
|
||||
...state,
|
||||
filteredInfo: {
|
||||
part_type: ["PAN,PAL,PAA,PAS,PASL"],
|
||||
part_type: ["PAN,PAL,PAA,PAP,PAS,PASL"],
|
||||
},
|
||||
});
|
||||
}}
|
||||
|
||||
@@ -26,12 +26,6 @@ export function JobsCreateJobsInfo({ bodyshop, form, selected }) {
|
||||
const { getFieldValue } = form;
|
||||
return (
|
||||
<div>
|
||||
<JobsDetailRatesParts
|
||||
jobRO={false}
|
||||
expanded
|
||||
required={selected && true}
|
||||
form={form}
|
||||
/>
|
||||
<Collapse defaultActiveKey="insurance">
|
||||
<Collapse.Panel
|
||||
key="insurance"
|
||||
@@ -312,6 +306,12 @@ export function JobsCreateJobsInfo({ bodyshop, form, selected }) {
|
||||
</LayoutFormRow>
|
||||
</Collapse.Panel>
|
||||
</Collapse>
|
||||
<JobsDetailRatesParts
|
||||
jobRO={false}
|
||||
expanded
|
||||
required={selected && true}
|
||||
form={form}
|
||||
/>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { DatePicker, Form, Tooltip } from "antd";
|
||||
import { DatePicker, Form, Statistic, Tooltip } from "antd";
|
||||
import React, { useMemo } from "react";
|
||||
import { useTranslation } from "react-i18next";
|
||||
import { connect } from "react-redux";
|
||||
@@ -23,6 +23,10 @@ export function JobsDetailDatesComponent({ jobRO, job, bodyshop }) {
|
||||
);
|
||||
}, [job.status, bodyshop.md_ro_statuses.post_production_statuses]);
|
||||
|
||||
const calcRepairDays =
|
||||
job.joblines.reduce((acc, val) => acc + val.mod_lb_hrs, 0) /
|
||||
(bodyshop.target_touchtime === 0 ? 1 : bodyshop.target_touchtime);
|
||||
|
||||
return (
|
||||
<div>
|
||||
<FormRow header={t("jobs.forms.estdates")}>
|
||||
@@ -52,6 +56,17 @@ export function JobsDetailDatesComponent({ jobRO, job, bodyshop }) {
|
||||
<Form.Item label={t("jobs.fields.actual_in")} name="actual_in">
|
||||
<DateTimePicker disabled={jobRO} />
|
||||
</Form.Item>
|
||||
<Tooltip
|
||||
title={t("jobs.labels.calc_repair_days_tt", {
|
||||
target_touchtime: bodyshop.target_touchtime,
|
||||
})}
|
||||
>
|
||||
<Statistic
|
||||
value={calcRepairDays}
|
||||
precision={1}
|
||||
title={t("jobs.labels.calc_repair_days")}
|
||||
/>
|
||||
</Tooltip>
|
||||
</FormRow>
|
||||
<FormRow header={t("jobs.forms.repairdates")}>
|
||||
<Form.Item
|
||||
|
||||
@@ -225,8 +225,10 @@ const r = ({ technician, state }) => {
|
||||
sortOrder:
|
||||
state.sortedInfo.columnKey === "totalhours" && state.sortedInfo.order,
|
||||
render: (text, record) =>
|
||||
record.labhrs.aggregate.sum.mod_lb_hrs +
|
||||
record.larhrs.aggregate.sum.mod_lb_hrs,
|
||||
(
|
||||
record.labhrs.aggregate.sum.mod_lb_hrs +
|
||||
record.larhrs.aggregate.sum.mod_lb_hrs
|
||||
).toFixed(2),
|
||||
},
|
||||
{
|
||||
title: i18n.t("production.labels.alert"),
|
||||
|
||||
@@ -1,6 +1,20 @@
|
||||
import moment from "moment";
|
||||
import React, { useMemo } from "react";
|
||||
export default function ProductionlistColumnTouchTime({ job }) {
|
||||
import { connect } from "react-redux";
|
||||
import { createStructuredSelector } from "reselect";
|
||||
import { selectBodyshop } from "../../redux/user/user.selectors";
|
||||
const mapStateToProps = createStructuredSelector({
|
||||
bodyshop: selectBodyshop,
|
||||
});
|
||||
const mapDispatchToProps = (dispatch) => ({
|
||||
//setUserLanguage: language => dispatch(setUserLanguage(language))
|
||||
});
|
||||
export default connect(
|
||||
mapStateToProps,
|
||||
mapDispatchToProps
|
||||
)(ProductionlistColumnTouchTime);
|
||||
|
||||
export function ProductionlistColumnTouchTime({ bodyshop, job }) {
|
||||
let ct = useMemo(() => {
|
||||
if (!!job.actual_in) {
|
||||
const totalHrs =
|
||||
@@ -18,5 +32,7 @@ export default function ProductionlistColumnTouchTime({ job }) {
|
||||
return 0;
|
||||
}, [job]);
|
||||
|
||||
return <span>{ct}</span>;
|
||||
const underTarget = ct < bodyshop.target_touchtime;
|
||||
|
||||
return <span style={{ color: underTarget && "tomato" }}>{ct}</span>;
|
||||
}
|
||||
|
||||
@@ -39,7 +39,7 @@ function VehicleDetailFormContainer({ vehicle, refetch }) {
|
||||
return (
|
||||
<>
|
||||
<PageHeader
|
||||
title={t("menus.header.owners")}
|
||||
title={t("menus.header.vehicles")}
|
||||
extra={
|
||||
<Button
|
||||
type="primary"
|
||||
|
||||
@@ -155,6 +155,13 @@ function JobsCreateContainer({ bodyshop, setBreadcrumbs, setSelectedHeader }) {
|
||||
layout="vertical"
|
||||
autoComplete={"off"}
|
||||
initialValues={{
|
||||
tax_tow_rt: bodyshop.bill_tax_rates.state_tax_rate / 100,
|
||||
tax_str_rt: bodyshop.bill_tax_rates.state_tax_rate / 100,
|
||||
tax_paint_mat_rt: bodyshop.bill_tax_rates.state_tax_rate / 100,
|
||||
tax_shop_mat_rt: bodyshop.bill_tax_rates.state_tax_rate / 100,
|
||||
tax_sub_rt: bodyshop.bill_tax_rates.state_tax_rate / 100,
|
||||
tax_lbr_rt: bodyshop.bill_tax_rates.state_tax_rate / 100,
|
||||
tax_levies_rt: bodyshop.bill_tax_rates.state_tax_rate / 100,
|
||||
parts_tax_rates: {
|
||||
PAA: {
|
||||
prt_type: "PAA",
|
||||
@@ -220,6 +227,30 @@ function JobsCreateContainer({ bodyshop, setBreadcrumbs, setSelectedHeader }) {
|
||||
prt_tax_in: true,
|
||||
prt_tax_rt: bodyshop.bill_tax_rates.state_tax_rate / 100,
|
||||
},
|
||||
PASL: {
|
||||
prt_type: "PASL",
|
||||
prt_discp: 0,
|
||||
prt_mktyp: false,
|
||||
prt_mkupp: 0,
|
||||
prt_tax_in: true,
|
||||
prt_tax_rt: bodyshop.bill_tax_rates.state_tax_rate / 100,
|
||||
},
|
||||
PAP: {
|
||||
prt_type: "PAP",
|
||||
prt_discp: 0,
|
||||
prt_mktyp: false,
|
||||
prt_mkupp: 0,
|
||||
prt_tax_in: true,
|
||||
prt_tax_rt: bodyshop.bill_tax_rates.state_tax_rate / 100,
|
||||
},
|
||||
PAO: {
|
||||
prt_type: "PAO",
|
||||
prt_discp: 0,
|
||||
prt_mktyp: false,
|
||||
prt_mkupp: 0,
|
||||
prt_tax_in: true,
|
||||
prt_tax_rt: bodyshop.bill_tax_rates.state_tax_rate / 100,
|
||||
},
|
||||
},
|
||||
}}
|
||||
>
|
||||
|
||||
@@ -1226,6 +1226,8 @@
|
||||
"rate": "PVRT Rate"
|
||||
},
|
||||
"ca_gst_all_if_null": "If the job is marked as a \"GST Registrant\" and this value is set to $0, the customer will be responsible for paying all of the GST by default. ",
|
||||
"calc_repair_days": "Calculated Repair Days",
|
||||
"calc_repair_days_tt": "This is the approximate number of days required to complete the repair according to the target touch time in your shop configuration (current set to {{target_touchtime}}).",
|
||||
"cards": {
|
||||
"customer": "Customer Information",
|
||||
"damage": "Area of Damage",
|
||||
|
||||
@@ -1226,6 +1226,8 @@
|
||||
"rate": ""
|
||||
},
|
||||
"ca_gst_all_if_null": "",
|
||||
"calc_repair_days": "",
|
||||
"calc_repair_days_tt": "",
|
||||
"cards": {
|
||||
"customer": "Información al cliente",
|
||||
"damage": "Área de Daño",
|
||||
|
||||
@@ -1226,6 +1226,8 @@
|
||||
"rate": ""
|
||||
},
|
||||
"ca_gst_all_if_null": "",
|
||||
"calc_repair_days": "",
|
||||
"calc_repair_days_tt": "",
|
||||
"cards": {
|
||||
"customer": "Informations client",
|
||||
"damage": "Zone de dommages",
|
||||
|
||||
Reference in New Issue
Block a user