From 49490e475400c99692aa9eaca9751cf1cfc59335 Mon Sep 17 00:00:00 2001 From: Patrick Fic <> Date: Tue, 16 Mar 2021 12:02:02 -0700 Subject: [PATCH 1/9] IO-763 IO-773 Label updates. --- bodyshop_translations.babel | 21 +++++++++++++++++++ ...b-reconciliation-bills-table.component.jsx | 2 +- client/src/translations/en_us/common.json | 1 + client/src/translations/es/common.json | 1 + client/src/translations/fr/common.json | 1 + 5 files changed, 25 insertions(+), 1 deletion(-) diff --git a/bodyshop_translations.babel b/bodyshop_translations.babel index 1fac37348..b2195fade 100644 --- a/bodyshop_translations.babel +++ b/bodyshop_translations.babel @@ -13420,6 +13420,27 @@ + + PAG + false + + + + + + en-US + false + + + es-MX + false + + + fr-CA + false + + + PAL false diff --git a/client/src/components/job-reconciliation-bills-table/job-reconciliation-bills-table.component.jsx b/client/src/components/job-reconciliation-bills-table/job-reconciliation-bills-table.component.jsx index bf25b4204..026364c11 100644 --- a/client/src/components/job-reconciliation-bills-table/job-reconciliation-bills-table.component.jsx +++ b/client/src/components/job-reconciliation-bills-table/job-reconciliation-bills-table.component.jsx @@ -35,7 +35,7 @@ export default function JobReconciliationBillsTable({ }`, }, { - title: t("billlines.fields.actua_price"), + title: t("billlines.fields.actual_price"), dataIndex: "actual_price", key: "actual_price", sorter: (a, b) => a.actual_price - b.actual_price, diff --git a/client/src/translations/en_us/common.json b/client/src/translations/en_us/common.json index fd4c94970..b2898eb9d 100644 --- a/client/src/translations/en_us/common.json +++ b/client/src/translations/en_us/common.json @@ -861,6 +861,7 @@ "PAA": "Aftermarket", "PAC": "Rechromed", "PAE": "Existing", + "PAG": "Glass", "PAL": "LKQ", "PAM": "Remanufactured", "PAN": "New/OEM", diff --git a/client/src/translations/es/common.json b/client/src/translations/es/common.json index 8b119b68e..872d22bc8 100644 --- a/client/src/translations/es/common.json +++ b/client/src/translations/es/common.json @@ -861,6 +861,7 @@ "PAA": "", "PAC": "", "PAE": "", + "PAG": "", "PAL": "", "PAM": "", "PAN": "", diff --git a/client/src/translations/fr/common.json b/client/src/translations/fr/common.json index 61f862c86..6561ab687 100644 --- a/client/src/translations/fr/common.json +++ b/client/src/translations/fr/common.json @@ -861,6 +861,7 @@ "PAA": "", "PAC": "", "PAE": "", + "PAG": "", "PAL": "", "PAM": "", "PAN": "", From 9ee5b8fcb0ee0e8be760de3a95150c0f80bb8101 Mon Sep 17 00:00:00 2001 From: Patrick Fic <> Date: Tue, 16 Mar 2021 12:12:58 -0700 Subject: [PATCH 2/9] IO-765 Resolve bill save issues. --- .../bill-detail-edit.container.jsx | 55 +++++++++---------- 1 file changed, 27 insertions(+), 28 deletions(-) diff --git a/client/src/components/bill-detail-edit/bill-detail-edit.container.jsx b/client/src/components/bill-detail-edit/bill-detail-edit.container.jsx index 6b1a8d303..bf4467758 100644 --- a/client/src/components/bill-detail-edit/bill-detail-edit.container.jsx +++ b/client/src/components/bill-detail-edit/bill-detail-edit.container.jsx @@ -41,7 +41,6 @@ export default function BillDetailEditcontainer() { billlines.forEach((il) => { delete il.__typename; - if (il.id) { updates.push( updateBillLine({ @@ -71,8 +70,11 @@ export default function BillDetailEditcontainer() { ); } }); - await Promise.all(updates); + + await refetch(); + form.resetFields(); + form.resetFields(); setUpdateLoading(false); }; @@ -92,32 +94,7 @@ export default function BillDetailEditcontainer() {
{ - return { - ...i, - joblineid: !!i.joblineid ? i.joblineid : "noline", - applicable_taxes: { - federal: - (i.applicable_taxes && i.applicable_taxes.federal) || - false, - state: - (i.applicable_taxes && i.applicable_taxes.state) || - false, - local: - (i.applicable_taxes && i.applicable_taxes.local) || - false, - }, - }; - }), - date: data.bills_by_pk ? moment(data.bills_by_pk.date) : null, - } - : {} - } + initialValues={transformData(data)} > Date: Tue, 16 Mar 2021 12:27:07 -0700 Subject: [PATCH 4/9] IO-768 Update Backorder Parts ETA --- .../parts-order-backorder-eta.component.jsx | 91 +++++++++++++++++++ .../parts-order-list-table.component.jsx | 11 ++- client/src/graphql/parts-orders.queries.js | 18 ++++ 3 files changed, 119 insertions(+), 1 deletion(-) create mode 100644 client/src/components/parts-order-backorder-eta/parts-order-backorder-eta.component.jsx diff --git a/client/src/components/parts-order-backorder-eta/parts-order-backorder-eta.component.jsx b/client/src/components/parts-order-backorder-eta/parts-order-backorder-eta.component.jsx new file mode 100644 index 000000000..5df9127e9 --- /dev/null +++ b/client/src/components/parts-order-backorder-eta/parts-order-backorder-eta.component.jsx @@ -0,0 +1,91 @@ +import { useMutation } from "@apollo/client"; +import { Button, Form, notification, Popover, Spin } from "antd"; +import React, { useState } from "react"; +import { useTranslation } from "react-i18next"; +import { connect } from "react-redux"; +import { createStructuredSelector } from "reselect"; +import { logImEXEvent } from "../../firebase/firebase.utils"; +import { MUTATION_UPDATE_BO_ETA } from "../../graphql/parts-orders.queries"; +import { selectBodyshop } from "../../redux/user/user.selectors"; +import { DateFormatter } from "../../utils/DateFormatter"; +import FormDatePicker from "../form-date-picker/form-date-picker.component"; +import { CalendarFilled } from "@ant-design/icons"; +const mapStateToProps = createStructuredSelector({ + bodyshop: selectBodyshop, +}); + +export function PartsOrderBackorderEta({ + backordered_eta, + partsOrderStatus, + partsLineId, + jobLineId, + disabled, + bodyshop, +}) { + const [visibility, setVisibility] = useState(false); + const [loading, setLoading] = useState(false); + const [updateBoDate] = useMutation(MUTATION_UPDATE_BO_ETA); + const { t } = useTranslation(); + const [form] = Form.useForm(); + + const isAlreadyBackordered = + bodyshop.md_order_statuses.default_bo === partsOrderStatus; + + const handleFinish = async (values) => { + setLoading(true); + logImEXEvent("job_parts_backorder_update_eta"); + + const result = await updateBoDate({ + variables: { + partsLineId, + partsOrder: { backordered_eta: values.eta }, + }, + }); + + if (!!result.errors) { + notification["error"]({ + message: t("parts_orders.errors.backordering", { + message: JSON.stringify(result.errors), + }), + }); + } + + setVisibility(false); + setLoading(false); + }; + + const handlePopover = (e) => { + setVisibility(true); + }; + + const popContent = ( +
+ + + + + + + +
+ ); + + return ( + + {backordered_eta} + {isAlreadyBackordered && ( + + )} + {loading && } + + ); +} + +export default connect(mapStateToProps, null)(PartsOrderBackorderEta); 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 3cc442633..78552bb98 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 @@ -14,6 +14,7 @@ import CurrencyFormatter from "../../utils/CurrencyFormatter"; import { DateFormatter } from "../../utils/DateFormatter"; import { alphaSort } from "../../utils/sorters"; import { TemplateList } from "../../utils/TemplateConstants"; +import PartsOrderBackorderEta from "../parts-order-backorder-eta/parts-order-backorder-eta.component"; import PartsOrderLineBackorderButton from "../parts-order-line-backorder-button/parts-order-line-backorder-button.component"; import PartsReceiveModalContainer from "../parts-receive-modal/parts-receive-modal.container"; import PrintWrapper from "../print-wrapper/print-wrapper.component"; @@ -245,7 +246,15 @@ export function PartsOrderListTableComponent({ title: t("parts_orders.fields.backordered_eta"), dataIndex: "backordered_eta", key: "backordered_eta", - render: (text, record) => {text}, + render: (text, record) => ( + + ), }, { title: t("general.labels.actions"), diff --git a/client/src/graphql/parts-orders.queries.js b/client/src/graphql/parts-orders.queries.js index 65de1f573..3559b4bc7 100644 --- a/client/src/graphql/parts-orders.queries.js +++ b/client/src/graphql/parts-orders.queries.js @@ -10,6 +10,24 @@ export const INSERT_NEW_PARTS_ORDERS = gql` } `; +export const MUTATION_UPDATE_BO_ETA = gql` + mutation MUTATION_UPDATE_BO_ETA( + $partsLineId: uuid! + $partsOrder: parts_order_lines_set_input + ) { + update_parts_order_lines( + where: { id: { _eq: $partsLineId } } + _set: $partsOrder + ) { + returning { + status + backordered_eta + id + } + } + } +`; + export const MUTATION_BACKORDER_PART_LINE = gql` mutation MUTATION_BACKORDER_PART_LINE( $jobLineId: uuid! From bf389e4dcbcaf24a1284d6b2705d3e904b41b844 Mon Sep 17 00:00:00 2001 From: Patrick Fic <> Date: Tue, 16 Mar 2021 13:15:26 -0700 Subject: [PATCH 5/9] IO-771 Reassign documents between jobs. --- .../jobs-document-gallery.reassign.component.jsx | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/client/src/components/jobs-documents-gallery/jobs-document-gallery.reassign.component.jsx b/client/src/components/jobs-documents-gallery/jobs-document-gallery.reassign.component.jsx index 6d6a2f4a1..c2b7ff948 100644 --- a/client/src/components/jobs-documents-gallery/jobs-document-gallery.reassign.component.jsx +++ b/client/src/components/jobs-documents-gallery/jobs-document-gallery.reassign.component.jsx @@ -54,11 +54,20 @@ export default function JobsDocumentsGalleryReassign({ galleryImages }) { const res = await axios.post("/media/rename", { documents: selectedImages.map((i) => { - return { id: i.id, from: i.key, to: i.key.replace("null", jobid) }; + //Need to check if the current key folder is null, or another job. + const currentKeys = i.key.split("/"); + currentKeys[1] = jobid; + currentKeys.join("/"); + return { id: i.id, from: i.key, to: currentKeys.join("/") }; }), }); - console.log(res.data); + res.data + .filter((d) => d.error) + .forEach((d) => { + notification["error"]({ message: t("documents.errors.updating") }); + console.error("Error updating job document", d); + }); const proms = []; From 441fdf1c624a38eb925d5ae682bf16cc1d7197a2 Mon Sep 17 00:00:00 2001 From: Patrick Fic <> Date: Tue, 16 Mar 2021 13:32:11 -0700 Subject: [PATCH 6/9] IO-772 RBAC for RBAC Controls --- client/src/components/rbac-wrapper/rbac-defaults.js | 2 +- .../rbac-wrapper/rbac-wrapper.component.jsx | 12 ++++++++++-- .../shop-info/shop-info.rbac.component.jsx | 5 +++-- 3 files changed, 14 insertions(+), 5 deletions(-) diff --git a/client/src/components/rbac-wrapper/rbac-defaults.js b/client/src/components/rbac-wrapper/rbac-defaults.js index 7efcb53bd..0da32826f 100644 --- a/client/src/components/rbac-wrapper/rbac-defaults.js +++ b/client/src/components/rbac-wrapper/rbac-defaults.js @@ -48,7 +48,7 @@ const ret = { "shiftclock:view": 2, "shop:vendors": 2, - "shop:rbac": 5, + "shop:rbac": 1, "shop:templates": 4, "temporarydocs:view": 2, diff --git a/client/src/components/rbac-wrapper/rbac-wrapper.component.jsx b/client/src/components/rbac-wrapper/rbac-wrapper.component.jsx index 81b5093c4..d9fb24870 100644 --- a/client/src/components/rbac-wrapper/rbac-wrapper.component.jsx +++ b/client/src/components/rbac-wrapper/rbac-wrapper.component.jsx @@ -28,10 +28,18 @@ function RbacWrapper({ ...restProps }) { const { t } = useTranslation(); + + console.log( + "********object :>> ", + action, + rbacDefaults[action], + bodyshop.md_rbac[action] + ); if ( (requiredAuthLevel && requiredAuthLevel <= authLevel) || - (bodyshop.md_rbac && bodyshop.md_rbac[action] <= authLevel) || - (!!!bodyshop.md_rbac && rbacDefaults[action] <= authLevel) + ((bodyshop.md_rbac && bodyshop.md_rbac[action]) || rbacDefaults[action]) <= + authLevel || + (!bodyshop.md_rbac && rbacDefaults[action] <= authLevel) ) return
{React.cloneElement(children, restProps)}
; diff --git a/client/src/components/shop-info/shop-info.rbac.component.jsx b/client/src/components/shop-info/shop-info.rbac.component.jsx index d47634888..daa189843 100644 --- a/client/src/components/shop-info/shop-info.rbac.component.jsx +++ b/client/src/components/shop-info/shop-info.rbac.component.jsx @@ -2,11 +2,12 @@ import { Form, InputNumber } from "antd"; import React from "react"; import { useTranslation } from "react-i18next"; import LayoutFormRow from "../layout-form-row/layout-form-row.component"; +import RbacWrapper from "../rbac-wrapper/rbac-wrapper.component"; export default function ShopInfoRbacComponent({ form }) { const { t } = useTranslation(); return ( -
+ -
+ ); } From c659e25142812dcfe97c082239271633c70c12d1 Mon Sep 17 00:00:00 2001 From: Patrick Fic <> Date: Tue, 16 Mar 2021 14:04:55 -0700 Subject: [PATCH 7/9] IO-769 Label change for CC. --- client/src/translations/en_us/common.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/client/src/translations/en_us/common.json b/client/src/translations/en_us/common.json index b2898eb9d..17dca9d16 100644 --- a/client/src/translations/en_us/common.json +++ b/client/src/translations/en_us/common.json @@ -559,8 +559,8 @@ "plate": "Plate Number", "purchasedate": "Purchase Date", "registrationexpires": "Registration Expires On", - "serviceenddate": "Service End Date", - "servicestartdate": "Service Start Date", + "serviceenddate": "Usage End Date", + "servicestartdate": "Usage Start Date", "status": "Status", "vin": "VIN", "year": "Year" From bda4db3ed5352c3eac344dfbd3a1eab540ea9a07 Mon Sep 17 00:00:00 2001 From: Patrick Fic <> Date: Tue, 16 Mar 2021 14:29:05 -0700 Subject: [PATCH 8/9] IO-779 Added shop sub status and blockers. --- bodyshop_translations.babel | 26 ++ .../jira-support-widget.component.jsx | 2 +- .../rbac-wrapper/rbac-wrapper.component.jsx | 6 - .../shop-sub-status.component.jsx | 33 ++ client/src/graphql/bodyshop.queries.js | 2 + .../pages/manage/manage.page.component.jsx | 420 ++++++++---------- .../pages/manage/manage.page.container.jsx | 11 +- client/src/translations/en_us/common.json | 3 + client/src/translations/es/common.json | 3 + client/src/translations/fr/common.json | 3 + .../down.yaml | 5 + .../up.yaml | 6 + .../down.yaml | 78 ++++ .../up.yaml | 79 ++++ hasura/migrations/metadata.yaml | 1 + 15 files changed, 435 insertions(+), 243 deletions(-) create mode 100644 client/src/components/shop-sub-status/shop-sub-status.component.jsx create mode 100644 hasura/migrations/1615929091635_alter_table_public_bodyshops_add_column_sub_status/down.yaml create mode 100644 hasura/migrations/1615929091635_alter_table_public_bodyshops_add_column_sub_status/up.yaml create mode 100644 hasura/migrations/1615929109833_update_permission_user_public_table_bodyshops/down.yaml create mode 100644 hasura/migrations/1615929109833_update_permission_user_public_table_bodyshops/up.yaml diff --git a/bodyshop_translations.babel b/bodyshop_translations.babel index b2195fade..3d67ca6d0 100644 --- a/bodyshop_translations.babel +++ b/bodyshop_translations.babel @@ -11882,6 +11882,32 @@
+ + sub_status + + + expired + false + + + + + + en-US + false + + + es-MX + false + + + fr-CA + false + + + + + sunday false diff --git a/client/src/components/jira-support-widget/jira-support-widget.component.jsx b/client/src/components/jira-support-widget/jira-support-widget.component.jsx index 54280f8dc..e450c297a 100644 --- a/client/src/components/jira-support-widget/jira-support-widget.component.jsx +++ b/client/src/components/jira-support-widget/jira-support-widget.component.jsx @@ -3,7 +3,7 @@ import React, { useEffect } from "react"; export default function JiraSupportComponent() { useScript(); - return
Jira Temp Widget
; + return
; } const useScript = () => { diff --git a/client/src/components/rbac-wrapper/rbac-wrapper.component.jsx b/client/src/components/rbac-wrapper/rbac-wrapper.component.jsx index d9fb24870..6da4f06a2 100644 --- a/client/src/components/rbac-wrapper/rbac-wrapper.component.jsx +++ b/client/src/components/rbac-wrapper/rbac-wrapper.component.jsx @@ -29,12 +29,6 @@ function RbacWrapper({ }) { const { t } = useTranslation(); - console.log( - "********object :>> ", - action, - rbacDefaults[action], - bodyshop.md_rbac[action] - ); if ( (requiredAuthLevel && requiredAuthLevel <= authLevel) || ((bodyshop.md_rbac && bodyshop.md_rbac[action]) || rbacDefaults[action]) <= diff --git a/client/src/components/shop-sub-status/shop-sub-status.component.jsx b/client/src/components/shop-sub-status/shop-sub-status.component.jsx new file mode 100644 index 000000000..b6f04b836 --- /dev/null +++ b/client/src/components/shop-sub-status/shop-sub-status.component.jsx @@ -0,0 +1,33 @@ +import { Button, Result } from "antd"; +import React from "react"; +import { useTranslation } from "react-i18next"; +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)(ShopSubStatus); + +export function ShopSubStatus({ bodyshop }) { + const { t } = useTranslation(); + const { sub_status } = bodyshop; + return ( + { + alert("Not implemented yet."); + }} + > + {t("general.actions.submitticket")} + + } + /> + ); +} diff --git a/client/src/graphql/bodyshop.queries.js b/client/src/graphql/bodyshop.queries.js index 880e1402d..33d359845 100644 --- a/client/src/graphql/bodyshop.queries.js +++ b/client/src/graphql/bodyshop.queries.js @@ -80,6 +80,7 @@ export const QUERY_BODYSHOP = gql` use_fippa md_payment_types md_hour_split + sub_status employees { id first_name @@ -158,6 +159,7 @@ export const UPDATE_SHOP = gql` use_fippa md_payment_types md_hour_split + sub_status employees { id first_name diff --git a/client/src/pages/manage/manage.page.component.jsx b/client/src/pages/manage/manage.page.component.jsx index 333c63cc9..ea7af17dc 100644 --- a/client/src/pages/manage/manage.page.component.jsx +++ b/client/src/pages/manage/manage.page.component.jsx @@ -12,8 +12,10 @@ import ChatAffixContainer from "../../components/chat-affix/chat-affix.container import ConflictComponent from "../../components/conflict/conflict.component"; import ErrorBoundary from "../../components/error-boundary/error-boundary.component"; import FcmNotification from "../../components/fcm-notification/fcm-notification.component"; +import ShopSubStatusComponent from "../../components/shop-sub-status/shop-sub-status.component"; //import FooterComponent from "../../components/footer/footer.component"; //Component Imports + import HeaderContainer from "../../components/header/header.container"; import JiraSupportComponent from "../../components/jira-support-widget/jira-support-widget.component"; import LoadingSpinner from "../../components/loading-spinner/loading-spinner.component"; @@ -21,7 +23,10 @@ import PartnerPingComponent from "../../components/partner-ping/partner-ping.com import PrintCenterModalContainer from "../../components/print-center-modal/print-center-modal.container"; import TestComponent from "../../components/_test/test.component"; import { QUERY_STRIPE_ID } from "../../graphql/bodyshop.queries"; -import { selectInstanceConflict } from "../../redux/user/user.selectors"; +import { + selectBodyshop, + selectInstanceConflict, +} from "../../redux/user/user.selectors"; import client from "../../utils/GraphQLClient"; import "./manage.page.styles.scss"; @@ -166,15 +171,198 @@ const stripePromise = new Promise((resolve, reject) => { const mapStateToProps = createStructuredSelector({ conflict: selectInstanceConflict, + bodyshop: selectBodyshop, }); -export function Manage({ match, conflict }) { +export function Manage({ match, conflict, bodyshop }) { const { t } = useTranslation(); useEffect(() => { document.title = t("titles.app"); }, [t]); + const AppRouteTable = ( + } + > + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + { + // + } + + + + + + + + + + + + + + + ); + + let PageContent; + + if (conflict) PageContent = ; + else if (bodyshop && bodyshop.sub_status !== "active") + PageContent = ; + else PageContent = AppRouteTable; + return (
@@ -183,233 +371,7 @@ export function Manage({ match, conflict }) { - - {conflict ? ( - - ) : ( - - } - > - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - { - // - } - - - - - - - - - - - - - - - )} - + {PageContent} diff --git a/client/src/pages/manage/manage.page.container.jsx b/client/src/pages/manage/manage.page.container.jsx index c7e06ecf3..c3e5903b6 100644 --- a/client/src/pages/manage/manage.page.container.jsx +++ b/client/src/pages/manage/manage.page.container.jsx @@ -1,15 +1,14 @@ import { useQuery } from "@apollo/client"; import React, { useEffect } from "react"; +import { useTranslation } from "react-i18next"; import { connect } from "react-redux"; +import { createStructuredSelector } from "reselect"; import AlertComponent from "../../components/alert/alert.component"; +import LoadingSpinner from "../../components/loading-spinner/loading-spinner.component"; import { QUERY_BODYSHOP } from "../../graphql/bodyshop.queries"; import { setBodyshop } from "../../redux/user/user.actions"; -import ManagePage from "./manage.page.component"; -import LoadingSpinner from "../../components/loading-spinner/loading-spinner.component"; -import { useTranslation } from "react-i18next"; -import { createStructuredSelector } from "reselect"; import { selectBodyshop } from "../../redux/user/user.selectors"; -import NoShop from "../../components/no-shop/no-shop.component"; +import ManagePage from "./manage.page.component"; const mapStateToProps = createStructuredSelector({ bodyshop: selectBodyshop }); @@ -32,8 +31,6 @@ function ManagePageContainer({ match, setBodyshop, bodyshop }) { return ; if (error) return ; - if (bodyshop && bodyshop.notfound) return ; - return ; } diff --git a/client/src/translations/en_us/common.json b/client/src/translations/en_us/common.json index 17dca9d16..1a2fef3e2 100644 --- a/client/src/translations/en_us/common.json +++ b/client/src/translations/en_us/common.json @@ -764,6 +764,9 @@ "sendagain": "Send Again", "sendby": "Send By", "signin": "Sign In", + "sub_status": { + "expired": "The subscription for this shop has expired. Please contact technical support to reactivate the subscription. " + }, "sunday": "Sunday", "text": "Text", "thursday": "Thursday", diff --git a/client/src/translations/es/common.json b/client/src/translations/es/common.json index 872d22bc8..b360f802d 100644 --- a/client/src/translations/es/common.json +++ b/client/src/translations/es/common.json @@ -764,6 +764,9 @@ "sendagain": "", "sendby": "", "signin": "", + "sub_status": { + "expired": "" + }, "sunday": "", "text": "", "thursday": "", diff --git a/client/src/translations/fr/common.json b/client/src/translations/fr/common.json index 6561ab687..6809b4952 100644 --- a/client/src/translations/fr/common.json +++ b/client/src/translations/fr/common.json @@ -764,6 +764,9 @@ "sendagain": "", "sendby": "", "signin": "", + "sub_status": { + "expired": "" + }, "sunday": "", "text": "", "thursday": "", diff --git a/hasura/migrations/1615929091635_alter_table_public_bodyshops_add_column_sub_status/down.yaml b/hasura/migrations/1615929091635_alter_table_public_bodyshops_add_column_sub_status/down.yaml new file mode 100644 index 000000000..caca3a404 --- /dev/null +++ b/hasura/migrations/1615929091635_alter_table_public_bodyshops_add_column_sub_status/down.yaml @@ -0,0 +1,5 @@ +- args: + cascade: false + read_only: false + sql: ALTER TABLE "public"."bodyshops" DROP COLUMN "sub_status"; + type: run_sql diff --git a/hasura/migrations/1615929091635_alter_table_public_bodyshops_add_column_sub_status/up.yaml b/hasura/migrations/1615929091635_alter_table_public_bodyshops_add_column_sub_status/up.yaml new file mode 100644 index 000000000..7dd40c290 --- /dev/null +++ b/hasura/migrations/1615929091635_alter_table_public_bodyshops_add_column_sub_status/up.yaml @@ -0,0 +1,6 @@ +- args: + cascade: false + read_only: false + sql: ALTER TABLE "public"."bodyshops" ADD COLUMN "sub_status" text NOT NULL DEFAULT + 'active'; + type: run_sql diff --git a/hasura/migrations/1615929109833_update_permission_user_public_table_bodyshops/down.yaml b/hasura/migrations/1615929109833_update_permission_user_public_table_bodyshops/down.yaml new file mode 100644 index 000000000..5a5ac5eec --- /dev/null +++ b/hasura/migrations/1615929109833_update_permission_user_public_table_bodyshops/down.yaml @@ -0,0 +1,78 @@ +- args: + role: user + table: + name: bodyshops + schema: public + type: drop_select_permission +- args: + permission: + allow_aggregations: false + columns: + - accountingconfig + - address1 + - address2 + - appt_alt_transport + - appt_colors + - appt_length + - bill_tax_rates + - city + - country + - created_at + - default_adjustment_rate + - deliverchecklist + - email + - enforce_class + - federal_tax_id + - id + - imexshopid + - inhousevendorid + - insurance_vendor_id + - intakechecklist + - logo_img_path + - md_categories + - md_classes + - md_hour_split + - md_ins_cos + - md_labor_rates + - md_messaging_presets + - md_notes_presets + - md_order_statuses + - md_parts_locations + - md_payment_types + - md_rbac + - md_referral_sources + - md_responsibility_centers + - md_ro_statuses + - messagingservicesid + - phone + - prodtargethrs + - production_config + - region_config + - schedule_end_time + - schedule_start_time + - scoreboard_target + - shopname + - shoprates + - speedprint + - ssbuckets + - state + - state_tax_id + - stripe_acct_id + - target_touchtime + - template_header + - textid + - updated_at + - use_fippa + - workingdays + - zip_post + computed_fields: [] + filter: + associations: + user: + authid: + _eq: X-Hasura-User-Id + role: user + table: + name: bodyshops + schema: public + type: create_select_permission diff --git a/hasura/migrations/1615929109833_update_permission_user_public_table_bodyshops/up.yaml b/hasura/migrations/1615929109833_update_permission_user_public_table_bodyshops/up.yaml new file mode 100644 index 000000000..7541894cb --- /dev/null +++ b/hasura/migrations/1615929109833_update_permission_user_public_table_bodyshops/up.yaml @@ -0,0 +1,79 @@ +- args: + role: user + table: + name: bodyshops + schema: public + type: drop_select_permission +- args: + permission: + allow_aggregations: false + columns: + - accountingconfig + - address1 + - address2 + - appt_alt_transport + - appt_colors + - appt_length + - bill_tax_rates + - city + - country + - created_at + - default_adjustment_rate + - deliverchecklist + - email + - enforce_class + - federal_tax_id + - id + - imexshopid + - inhousevendorid + - insurance_vendor_id + - intakechecklist + - logo_img_path + - md_categories + - md_classes + - md_hour_split + - md_ins_cos + - md_labor_rates + - md_messaging_presets + - md_notes_presets + - md_order_statuses + - md_parts_locations + - md_payment_types + - md_rbac + - md_referral_sources + - md_responsibility_centers + - md_ro_statuses + - messagingservicesid + - phone + - prodtargethrs + - production_config + - region_config + - schedule_end_time + - schedule_start_time + - scoreboard_target + - shopname + - shoprates + - speedprint + - ssbuckets + - state + - state_tax_id + - stripe_acct_id + - sub_status + - target_touchtime + - template_header + - textid + - updated_at + - use_fippa + - workingdays + - zip_post + computed_fields: [] + filter: + associations: + user: + authid: + _eq: X-Hasura-User-Id + role: user + table: + name: bodyshops + schema: public + type: create_select_permission diff --git a/hasura/migrations/metadata.yaml b/hasura/migrations/metadata.yaml index 39ac4dae1..dfff958f5 100644 --- a/hasura/migrations/metadata.yaml +++ b/hasura/migrations/metadata.yaml @@ -777,6 +777,7 @@ tables: - state - state_tax_id - stripe_acct_id + - sub_status - target_touchtime - template_header - textid From 0dd88f244f6f488b2b0d4deb66e8b53281ca2155 Mon Sep 17 00:00:00 2001 From: Patrick Fic <> Date: Tue, 16 Mar 2021 14:51:11 -0700 Subject: [PATCH 9/9] IO-770 Remove seconds from shop config. --- .../components/shop-info/shop-info.scheduling.component.jsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/client/src/components/shop-info/shop-info.scheduling.component.jsx b/client/src/components/shop-info/shop-info.scheduling.component.jsx index 6caf2d0f2..77647a62e 100644 --- a/client/src/components/shop-info/shop-info.scheduling.component.jsx +++ b/client/src/components/shop-info/shop-info.scheduling.component.jsx @@ -30,7 +30,7 @@ export default function ShopInfoSchedulingComponent({ form }) { }, ]} > - + - + {t("bodyshop.labels.apptcolors")}