From 34422dfef78cca553fe7ec784c4a0c46f028e2bc Mon Sep 17 00:00:00 2001 From: Patrick Fic <> Date: Tue, 13 Jul 2021 11:02:54 -0700 Subject: [PATCH 1/5] IO-1255 Resolve parts return and posting for non-defined lines --- .../parts-order-list-table.component.jsx | 2 +- .../parts-order-modal/parts-order-modal.container.jsx | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/client/src/components/parts-order-list-table/parts-order-list-table.component.jsx b/client/src/components/parts-order-list-table/parts-order-list-table.component.jsx index 4c904776b..99a8df5db 100644 --- a/client/src/components/parts-order-list-table/parts-order-list-table.component.jsx +++ b/client/src/components/parts-order-list-table/parts-order-list-table.component.jsx @@ -157,7 +157,7 @@ export function PartsOrderListTableComponent({ quantity: pol.quantity, actual_price: pol.act_price, - cost_center: pol.jobline.part_type + cost_center: pol.jobline?.part_type ? responsibilityCenters.defaults.costs[ pol.jobline.part_type ] || null diff --git a/client/src/components/parts-order-modal/parts-order-modal.container.jsx b/client/src/components/parts-order-modal/parts-order-modal.container.jsx index 6bb66bc62..3fbba36c3 100644 --- a/client/src/components/parts-order-modal/parts-order-modal.container.jsx +++ b/client/src/components/parts-order-modal/parts-order-modal.container.jsx @@ -101,7 +101,9 @@ export function PartsOrderModalContainer({ const jobLinesResult = await updateJobLines({ variables: { - ids: values.parts_order_lines.data.map((item) => item.job_line_id), + ids: values.parts_order_lines.data + .filter((item) => item.job_line_id) + .map((item) => item.job_line_id), status: isReturn ? bodyshop.md_order_statuses.default_returned || "Returned*" : bodyshop.md_order_statuses.default_ordered || "Ordered*", From 33e2201524a79434b9fad3becb0b5188846ada82 Mon Sep 17 00:00:00 2001 From: Patrick Fic <> Date: Tue, 13 Jul 2021 11:09:15 -0700 Subject: [PATCH 2/5] IO-1256 Payments on job missing field & edit from list. --- .../job-payments/job-payments.component.jsx | 34 +++++++++++++------ client/src/graphql/jobs.queries.js | 3 ++ 2 files changed, 27 insertions(+), 10 deletions(-) diff --git a/client/src/components/job-payments/job-payments.component.jsx b/client/src/components/job-payments/job-payments.component.jsx index 50a12d6db..09dd9f831 100644 --- a/client/src/components/job-payments/job-payments.component.jsx +++ b/client/src/components/job-payments/job-payments.component.jsx @@ -1,4 +1,5 @@ import { Button, Card, Space, Table } from "antd"; +import { EditFilled } from "@ant-design/icons"; import Dinero from "dinero.js"; import React, { useMemo, useState } from "react"; import { useTranslation } from "react-i18next"; @@ -115,16 +116,29 @@ export function JobPayments({ dataIndex: "actions", key: "actions", render: (text, record) => ( - + + + + ), }, ]; diff --git a/client/src/graphql/jobs.queries.js b/client/src/graphql/jobs.queries.js index eb89e38fd..1546da001 100644 --- a/client/src/graphql/jobs.queries.js +++ b/client/src/graphql/jobs.queries.js @@ -559,6 +559,7 @@ export const GET_JOB_BY_PK = gql` } payments { id + jobid amount payer created_at @@ -566,6 +567,8 @@ export const GET_JOB_BY_PK = gql` transactionid memo date + type + exportedat } cccontracts { id From a288a1a2a4c9ed18013567eb03885ad69b7ce5a7 Mon Sep 17 00:00:00 2001 From: Patrick Fic <> Date: Tue, 13 Jul 2021 11:49:27 -0700 Subject: [PATCH 3/5] IO-1250 Mark job as PST Exempt --- bodyshop_translations.babel | 44 ++++++++++++++- .../jobs-create-jobs-info.component.jsx | 5 +- .../jobs-detail-rates.component.jsx | 28 ++++++++-- .../jobs-detail-rates.parts.component.jsx | 6 +- .../jobs-mark-pst-exempt.component.jsx | 55 +++++++++++++++++++ client/src/translations/en_us/common.json | 2 + client/src/translations/es/common.json | 2 + client/src/translations/fr/common.json | 2 + 8 files changed, 136 insertions(+), 8 deletions(-) create mode 100644 client/src/components/jobs-mark-pst-exempt/jobs-mark-pst-exempt.component.jsx diff --git a/bodyshop_translations.babel b/bodyshop_translations.babel index cf3050035..0bb1588a7 100644 --- a/bodyshop_translations.babel +++ b/bodyshop_translations.babel @@ -1,4 +1,4 @@ - +