diff --git a/client/.env.development.promanager b/client/.env.development.promanager index 70b8b0fdd..15fa08bce 100644 --- a/client/.env.development.promanager +++ b/client/.env.development.promanager @@ -1,7 +1,7 @@ VITE_APP_GRAPHQL_ENDPOINT=https://db.dev.bodyshop.app/v1/graphql VITE_APP_GRAPHQL_ENDPOINT_WS=wss://db.dev.bodyshop.app/v1/graphql VITE_APP_GA_CODE=231099835 -VITE_APP_FIREBASE_CONFIG={ "apiKey": "AIzaSyAuLQR9SV5LsVxjU8wh9hvFLdhcAHU6cxE", "authDomain": "rome-prod-1.firebaseapp.com", "projectId": "rome-prod-1", "storageBucket": "rome-prod-1.appspot.com", "messagingSenderId": "147786367145", "appId": "1:147786367145:web:9d4cba68071c3f29a8a9b8", "measurementId": "G-G8Z9DRHTZS"} +VITE_APP_FIREBASE_CONFIG={"apiKey":"AIzaSyDPLT8GiDHDR1R4nI66Qi0BY1aYviDPioc","authDomain":"imex-dev.firebaseapp.com","databaseURL":"https://imex-dev.firebaseio.com","projectId":"imex-dev","storageBucket":"imex-dev.appspot.com","messagingSenderId":"759548147434","appId":"1:759548147434:web:e8239868a48ceb36700993","measurementId":"G-K5XRBVVB4S"} VITE_APP_CLOUDINARY_ENDPOINT_API=https://api.cloudinary.com/v1_1/io-test VITE_APP_CLOUDINARY_ENDPOINT=https://res.cloudinary.com/io-test VITE_APP_CLOUDINARY_API_KEY=957865933348715 diff --git a/client/src/App/App.jsx b/client/src/App/App.jsx index 4b80fb38e..1864bd623 100644 --- a/client/src/App/App.jsx +++ b/client/src/App/App.jsx @@ -7,9 +7,7 @@ import { connect } from "react-redux"; import { Route, Routes } from "react-router-dom"; import { createStructuredSelector } from "reselect"; import DocumentEditorContainer from "../components/document-editor/document-editor.container"; -import ErrorBoundary from "../components/error-boundary/error-boundary.component"; - -//Component Imports +import ErrorBoundary from "../components/error-boundary/error-boundary.component"; // Component Imports import LoadingSpinner from "../components/loading-spinner/loading-spinner.component"; import DisclaimerPage from "../pages/disclaimer/disclaimer.page"; import LandingPage from "../pages/landing/landing.page"; @@ -23,20 +21,21 @@ import "./App.styles.scss"; import handleBeta from "../utils/betaHandler"; import Eula from "../components/eula/eula.component"; import InstanceRenderMgr from "../utils/instanceRenderMgr"; -import { ProductFruits } from "react-product-fruits"; +import ProductFruitsWrapper from "./ProductFruitsWrapper.jsx"; const ResetPassword = lazy(() => import("../pages/reset-password/reset-password.component")); const ManagePage = lazy(() => import("../pages/manage/manage.page.container")); const SignInPage = lazy(() => import("../pages/sign-in/sign-in.page")); - const CsiPage = lazy(() => import("../pages/csi/csi.container.page")); const MobilePaymentContainer = lazy(() => import("../pages/mobile-payment/mobile-payment.container")); + const mapStateToProps = createStructuredSelector({ currentUser: selectCurrentUser, online: selectOnline, bodyshop: selectBodyshop, currentEula: selectCurrentEula }); + const mapDispatchToProps = (dispatch) => ({ checkUserSession: () => dispatch(checkUserSession()), setOnline: (isOnline) => dispatch(setOnline(isOnline)) @@ -60,11 +59,11 @@ export function App({ bodyshop, checkUserSession, currentUser, online, setOnline // Associate event listeners, memoize to prevent multiple listeners being added useEffect(() => { - const offlineListener = (e) => { + const offlineListener = () => { setOnline(false); }; - const onlineListener = (e) => { + const onlineListener = () => { setOnline(true); }; @@ -98,7 +97,7 @@ export function App({ bodyshop, checkUserSession, currentUser, online, setOnline InstanceRenderMgr({ imex: "gvfvfw/bodyshopapp", rome: "rome-online/rome-online", - promanager: "" //TODO:AIO Add in log rocket for promanager instances. + promanager: "" // TODO: AIO Add in log rocket for promanager instances. }) ); } @@ -111,24 +110,20 @@ export function App({ bodyshop, checkUserSession, currentUser, online, setOnline handleBeta(); - if (!online) + if (!online) { return ( { - window.location.reload(); - }} - > + } /> ); + } if (currentEula && !currentUser.eulaIsAccepted) { return ; @@ -147,19 +142,7 @@ export function App({ bodyshop, checkUserSession, currentUser, online, setOnline /> } > - + { + return ( + currentUser?.authorized === true && + currentUser?.email && ( + + ) + ); +}); + +export default ProductFruitsWrapper; diff --git a/client/src/components/shop-employees/shop-employees-list.component.jsx b/client/src/components/shop-employees/shop-employees-list.component.jsx index 2add19f34..d6b41bad2 100644 --- a/client/src/components/shop-employees/shop-employees-list.component.jsx +++ b/client/src/components/shop-employees/shop-employees-list.component.jsx @@ -63,7 +63,7 @@ export default function ShopEmployeesListComponent({ loading, employees }) { value: false } ], - onFilter: (value, record) => value === record.flate_rate, + onFilter: (value, record) => value === record.flat_rate, render: (text, record) => record.flat_rate ? t("employees.labels.flat_rate") : t("employees.labels.straight_time") }, diff --git a/client/src/translations/en_us/common.json b/client/src/translations/en_us/common.json index 6b76a6ed0..b46f3c553 100644 --- a/client/src/translations/en_us/common.json +++ b/client/src/translations/en_us/common.json @@ -2920,7 +2920,8 @@ "parts_not_recieved_vendor": "Parts Not Received by Vendor", "parts_received_not_scheduled": "Parts Received for Jobs Not Scheduled", "payments_by_date": "Payments by Date", - "payments_by_date_type": "Payments by Date and Type", + "payments_by_date_payment": "Payments by Date and Payment Type", + "payments_by_date_type": "Payments by Date and Customer Type", "production_by_category": "Production by Category", "production_by_category_one": "Production filtered by Category", "production_by_csr": "Production by CSR", diff --git a/client/src/translations/es/common.json b/client/src/translations/es/common.json index 48d6f107d..6c2b46890 100644 --- a/client/src/translations/es/common.json +++ b/client/src/translations/es/common.json @@ -2920,6 +2920,7 @@ "parts_not_recieved_vendor": "", "parts_received_not_scheduled": "", "payments_by_date": "", + "payments_by_date_payment": "", "payments_by_date_type": "", "production_by_category": "", "production_by_category_one": "", diff --git a/client/src/translations/fr/common.json b/client/src/translations/fr/common.json index 3fd409e2a..8003cf969 100644 --- a/client/src/translations/fr/common.json +++ b/client/src/translations/fr/common.json @@ -2920,6 +2920,7 @@ "parts_not_recieved_vendor": "", "parts_received_not_scheduled": "", "payments_by_date": "", + "payments_by_date_payment": "", "payments_by_date_type": "", "production_by_category": "", "production_by_category_one": "", diff --git a/client/src/utils/TemplateConstants.js b/client/src/utils/TemplateConstants.js index 8fda63504..2aa482fb6 100644 --- a/client/src/utils/TemplateConstants.js +++ b/client/src/utils/TemplateConstants.js @@ -1194,6 +1194,17 @@ export const TemplateList = (type, context) => { }, group: "customers" }, + payments_by_date_payment: { + title: i18n.t("reportcenter.templates.payments_by_date_payment"), + subject: i18n.t("reportcenter.templates.payments_by_date_payment"), + key: "payments_by_date_payment", + disabled: false, + rangeFilter: { + object: i18n.t("reportcenter.labels.objects.payments"), + field: i18n.t("payments.fields.date") + }, + group: "customers" + }, schedule: { title: i18n.t("reportcenter.templates.schedule"), subject: i18n.t("reportcenter.templates.schedule"),