From dea7fd71efb5cc3d8952509f8b55386de9174eeb Mon Sep 17 00:00:00 2001 From: Allan Carr Date: Wed, 17 Jan 2024 09:41:57 -0800 Subject: [PATCH 01/10] IO-2600 Tech Console Job Logout Console Log --- .../tech-job-clock-out-button.component.jsx | 3 --- 1 file changed, 3 deletions(-) diff --git a/client/src/components/tech-job-clock-out-button/tech-job-clock-out-button.component.jsx b/client/src/components/tech-job-clock-out-button/tech-job-clock-out-button.component.jsx index d1c5c3528..98369c860 100644 --- a/client/src/components/tech-job-clock-out-button/tech-job-clock-out-button.component.jsx +++ b/client/src/components/tech-job-clock-out-button/tech-job-clock-out-button.component.jsx @@ -166,9 +166,6 @@ export function TechClockOffButton({ }, ({ getFieldValue }) => ({ validator(rule, value) { - console.log( - bodyshop.tt_enforce_hours_for_tech_console - ); if (!bodyshop.tt_enforce_hours_for_tech_console) { return Promise.resolve(); } From 636be8989e952f351b2195d06a6bbc70993937b6 Mon Sep 17 00:00:00 2001 From: Allan Carr Date: Wed, 17 Jan 2024 14:22:47 -0800 Subject: [PATCH 02/10] IO-2589 Allow Company Only for Customer Creation --- .../jobs-create-owner-info.new.component.jsx | 29 +++++++++++++++---- 1 file changed, 23 insertions(+), 6 deletions(-) diff --git a/client/src/components/jobs-create-owner-info/jobs-create-owner-info.new.component.jsx b/client/src/components/jobs-create-owner-info/jobs-create-owner-info.new.component.jsx index 2dea9a657..da2a1b1a5 100644 --- a/client/src/components/jobs-create-owner-info/jobs-create-owner-info.new.component.jsx +++ b/client/src/components/jobs-create-owner-info/jobs-create-owner-info.new.component.jsx @@ -19,10 +19,13 @@ export default function JobsCreateOwnerInfoNewComponent() { label={t("owners.fields.ownr_ln")} name={["owner", "data", "ownr_ln"]} rules={[ - { - required: state.owner.new, + ({ getFieldValue }) => ({ + required: + state.owner.new && + (!getFieldValue(["owner", "data", "ownr_co_nm"]) || + getFieldValue(["owner", "data", "ownr_co_nm"]) === ""), //message: t("general.validation.required"), - }, + }), ]} > @@ -31,10 +34,13 @@ export default function JobsCreateOwnerInfoNewComponent() { label={t("owners.fields.ownr_fn")} name={["owner", "data", "ownr_fn"]} rules={[ - { - required: state.owner.new, + ({ getFieldValue }) => ({ + required: + state.owner.new && + (!getFieldValue(["owner", "data", "ownr_co_nm"]) || + getFieldValue(["owner", "data", "ownr_co_nm"]) === ""), //message: t("general.validation.required"), - }, + }), ]} > @@ -51,6 +57,17 @@ export default function JobsCreateOwnerInfoNewComponent() { ({ + required: + state.owner.new && + (!getFieldValue(["owner", "data", "ownr_ln"]) || + !getFieldValue(["owner", "data", "ownr_fn"]) || + getFieldValue(["owner", "data", "ownr_ln"]) === "" || + getFieldValue(["owner", "data", "ownr_fn"]) === ""), + //message: t("general.validation.required"), + }), + ]} > From c72b4a25cfaa7404d7f07b60ab62f8f168248936 Mon Sep 17 00:00:00 2001 From: Dave Richer Date: Wed, 17 Jan 2024 19:54:03 -0500 Subject: [PATCH 03/10] - progress Signed-off-by: Dave Richer --- client/src/index.js | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/client/src/index.js b/client/src/index.js index 9bf4faddb..9bcdc55ec 100644 --- a/client/src/index.js +++ b/client/src/index.js @@ -12,7 +12,6 @@ import { persistor, store } from "./redux/store"; import reportWebVitals from "./reportWebVitals"; import "./translations/i18n"; import "./utils/CleanAxios"; -import {ConfigProvider} from "antd"; import {defaultTheme} from "@ant-design/compatible"; //import { BrowserTracing } from "@sentry/tracing"; //import "antd/dist/antd.css"; @@ -67,7 +66,7 @@ function App() { // https://ant.design/docs/react/migrate-less-variables // TODO - Client Update - At a later time it might be worth removing these defaults ReactDOM.createRoot(document.getElementById('root')).render( - + ); From 2699b80e1aa2ddd96b7f4615e7ee687956e2702d Mon Sep 17 00:00:00 2001 From: Dave Richer Date: Wed, 17 Jan 2024 20:02:41 -0500 Subject: [PATCH 04/10] - adjust circle ci Signed-off-by: Dave Richer --- .circleci/config.yml | 49 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 49 insertions(+) diff --git a/.circleci/config.yml b/.circleci/config.yml index 2e047be49..ac700fdb7 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -69,6 +69,26 @@ jobs: to: "s3://imex-online-production/" - jira/notify + app-beta-build: + docker: + - image: cimg/node:18.18.2 + resource_class: large + working_directory: ~/repo/client + + steps: + - checkout: + path: ~/repo + - run: + name: Install Dependencies + command: npm i + + - run: npm run build + + - aws-s3/sync: + from: build + to: "s3://imex-online-beta/" + - jira/notify + test-hasura-migrate: docker: - image: cimg/node:16.15.0 @@ -119,6 +139,27 @@ jobs: to: "s3://imex-online-test/" - jira/notify + test-app-beta-build: + docker: + - image: cimg/node:18.18.2 + + working_directory: ~/repo/client + + steps: + - checkout: + path: ~/repo + + - run: + name: Install Dependencies + command: npm i + + - run: npm run build + + - aws-s3/sync: + from: build + to: "s3://imex-online-test-beta/" + - jira/notify + admin-app-build: docker: - image: cimg/node:16.15.0 @@ -160,6 +201,10 @@ workflows: filters: branches: only: master + - app-beta-build: + filters: + branches: + only: master-beta - hasura-migrate: secret: ${HASURA_PROD_SECRET} filters: @@ -169,6 +214,10 @@ workflows: filters: branches: only: test + - test-app-beta-build: + filters: + branches: + only: test-beta - test-hasura-migrate: secret: ${HASURA_TEST_SECRET} filters: From eb96f6467ffe5445e9b493b2dfe3f934c40f2cb3 Mon Sep 17 00:00:00 2001 From: Dave Richer Date: Wed, 17 Jan 2024 20:03:55 -0500 Subject: [PATCH 05/10] - adjust circle ci Signed-off-by: Dave Richer --- client/src/index.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/client/src/index.js b/client/src/index.js index 9bcdc55ec..f93b74910 100644 --- a/client/src/index.js +++ b/client/src/index.js @@ -12,7 +12,6 @@ import { persistor, store } from "./redux/store"; import reportWebVitals from "./reportWebVitals"; import "./translations/i18n"; import "./utils/CleanAxios"; -import {defaultTheme} from "@ant-design/compatible"; //import { BrowserTracing } from "@sentry/tracing"; //import "antd/dist/antd.css"; // import "antd/dist/antd.less"; @@ -64,6 +63,10 @@ function App() { // Used for ANTD Component Tokens // https://ant.design/docs/react/migrate-less-variables +function ConfigProvider(props) { + return null; +} + // TODO - Client Update - At a later time it might be worth removing these defaults ReactDOM.createRoot(document.getElementById('root')).render( From 1cb4b228ce7d1ebbaa800133526ca5b51a3f73c4 Mon Sep 17 00:00:00 2001 From: Dave Richer Date: Wed, 17 Jan 2024 20:05:38 -0500 Subject: [PATCH 06/10] - fix issue Signed-off-by: Dave Richer --- client/src/index.js | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/client/src/index.js b/client/src/index.js index f93b74910..2a4118568 100644 --- a/client/src/index.js +++ b/client/src/index.js @@ -12,6 +12,7 @@ import { persistor, store } from "./redux/store"; import reportWebVitals from "./reportWebVitals"; import "./translations/i18n"; import "./utils/CleanAxios"; +import { ConfigProvider } from "antd"; //import { BrowserTracing } from "@sentry/tracing"; //import "antd/dist/antd.css"; // import "antd/dist/antd.less"; @@ -63,11 +64,6 @@ function App() { // Used for ANTD Component Tokens // https://ant.design/docs/react/migrate-less-variables -function ConfigProvider(props) { - return null; -} - -// TODO - Client Update - At a later time it might be worth removing these defaults ReactDOM.createRoot(document.getElementById('root')).render( From 572963d9871dfb593f497ce1b9fd9659f6dd37e4 Mon Sep 17 00:00:00 2001 From: Allan Carr Date: Wed, 17 Jan 2024 17:09:17 -0800 Subject: [PATCH 07/10] IO-2606 Modal Closeable for Schedule Appointment --- .../schedule-job-modal/schedule-job-modal.container.jsx | 1 + 1 file changed, 1 insertion(+) diff --git a/client/src/components/schedule-job-modal/schedule-job-modal.container.jsx b/client/src/components/schedule-job-modal/schedule-job-modal.container.jsx index 19c360a21..19d6d4a37 100644 --- a/client/src/components/schedule-job-modal/schedule-job-modal.container.jsx +++ b/client/src/components/schedule-job-modal/schedule-job-modal.container.jsx @@ -216,6 +216,7 @@ export function ScheduleJobModalContainer({ okButtonProps={{ loading: loading, }} + closable={false} >
Date: Wed, 17 Jan 2024 20:21:34 -0500 Subject: [PATCH 08/10] - Generate sourcemaps Signed-off-by: Dave Richer --- client/.env.production | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/client/.env.production b/client/.env.production index a4cdecee5..cdf721dcb 100644 --- a/client/.env.production +++ b/client/.env.production @@ -1,4 +1,4 @@ -GENERATE_SOURCEMAP=false +GENERATE_SOURCEMAP=true REACT_APP_GRAPHQL_ENDPOINT=https://db.imex.online/v1/graphql REACT_APP_GRAPHQL_ENDPOINT_WS=wss://db.imex.online/v1/graphql REACT_APP_GA_CODE=231103507 From 94dd7c6f695b863de466156e82509c3a0c659a8e Mon Sep 17 00:00:00 2001 From: Dave Richer Date: Wed, 17 Jan 2024 20:25:09 -0500 Subject: [PATCH 09/10] - Update build resource Signed-off-by: Dave Richer --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index ac700fdb7..a7af04efa 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -142,7 +142,7 @@ jobs: test-app-beta-build: docker: - image: cimg/node:18.18.2 - + resource_class: large working_directory: ~/repo/client steps: From 9ee10dc5f8509df3afb4a3473e2f0c3868ef7447 Mon Sep 17 00:00:00 2001 From: Allan Carr Date: Wed, 17 Jan 2024 17:52:14 -0800 Subject: [PATCH 10/10] IO-2601 Tech Console Titles --- .../src/components/tech-login/tech-login.component.jsx | 8 ++++++-- .../pages/tech-job-clock/tech-job-clock.component.jsx | 9 ++++++++- client/src/pages/tech-lookup/tech-lookup.container.jsx | 9 ++++++++- .../tech-shift-clock/tech-shift-clock.component.jsx | 9 ++++++++- client/src/translations/en_us/common.json | 8 ++++++-- client/src/translations/es/common.json | 6 +++++- client/src/translations/fr/common.json | 6 +++++- 7 files changed, 46 insertions(+), 9 deletions(-) diff --git a/client/src/components/tech-login/tech-login.component.jsx b/client/src/components/tech-login/tech-login.component.jsx index 502b20cbf..c266803a5 100644 --- a/client/src/components/tech-login/tech-login.component.jsx +++ b/client/src/components/tech-login/tech-login.component.jsx @@ -1,7 +1,8 @@ import { Button, Form, Input } from "antd"; -import React from "react"; +import React, { useEffect } from "react"; import { useTranslation } from "react-i18next"; import { connect } from "react-redux"; +import { Redirect } from "react-router-dom"; import { createStructuredSelector } from "reselect"; import { techLoginStart } from "../../redux/tech/tech.actions"; import { @@ -11,7 +12,6 @@ import { } from "../../redux/tech/tech.selectors"; import AlertComponent from "../alert/alert.component"; import "./tech-login.styles.scss"; -import { Redirect } from "react-router-dom"; const mapStateToProps = createStructuredSelector({ technician: selectTechnician, @@ -35,6 +35,10 @@ export function TechLogin({ techLoginStart(values); }; + useEffect(() => { + document.title = t("titles.techconsole"); + }, [t]); + return (
{technician ? : null} diff --git a/client/src/pages/tech-job-clock/tech-job-clock.component.jsx b/client/src/pages/tech-job-clock/tech-job-clock.component.jsx index 0d64068eb..c22b68eed 100644 --- a/client/src/pages/tech-job-clock/tech-job-clock.component.jsx +++ b/client/src/pages/tech-job-clock/tech-job-clock.component.jsx @@ -1,10 +1,17 @@ import { Divider } from "antd"; -import React from "react"; +import React, { useEffect } from "react"; +import { useTranslation } from "react-i18next"; import TechClockInFormContainer from "../../components/tech-job-clock-in-form/tech-job-clock-in-form.container"; import TechClockedInList from "../../components/tech-job-clocked-in-list/tech-job-clocked-in-list.component"; import TechJobStatistics from "../../components/tech-job-statistics/tech-job-statistics.component"; export default function TechClockComponent() { + const { t } = useTranslation(); + + useEffect(() => { + document.title = t("titles.techjobclock"); + }, [t]); + return (
diff --git a/client/src/pages/tech-lookup/tech-lookup.container.jsx b/client/src/pages/tech-lookup/tech-lookup.container.jsx index 1297220b9..e24f8f661 100644 --- a/client/src/pages/tech-lookup/tech-lookup.container.jsx +++ b/client/src/pages/tech-lookup/tech-lookup.container.jsx @@ -1,9 +1,16 @@ -import React from "react"; +import React, { useEffect } from "react"; +import { useTranslation } from "react-i18next"; import RbacWrapperComponent from "../../components/rbac-wrapper/rbac-wrapper.component"; import TechLookupJobsDrawer from "../../components/tech-lookup-jobs-drawer/tech-lookup-jobs-drawer.component"; import TechLookupJobsList from "../../components/tech-lookup-jobs-list/tech-lookup-jobs-list.component"; export default function TechLookupContainer() { + const { t } = useTranslation(); + + useEffect(() => { + document.title = t("titles.techjoblookup"); + }, [t]); + return (
diff --git a/client/src/pages/tech-shift-clock/tech-shift-clock.component.jsx b/client/src/pages/tech-shift-clock/tech-shift-clock.component.jsx index 52e0e99c7..2dad65e64 100644 --- a/client/src/pages/tech-shift-clock/tech-shift-clock.component.jsx +++ b/client/src/pages/tech-shift-clock/tech-shift-clock.component.jsx @@ -1,7 +1,14 @@ -import React from "react"; +import React, { useEffect } from "react"; +import { useTranslation } from "react-i18next"; import TimeTicketShift from "../../components/time-ticket-shift/time-ticket-shift.container"; export default function TechShiftClock() { + const { t } = useTranslation(); + + useEffect(() => { + document.title = t("titles.techshiftclock"); + }, [t]); + return (
diff --git a/client/src/translations/en_us/common.json b/client/src/translations/en_us/common.json index 09798f0a5..13555e364 100644 --- a/client/src/translations/en_us/common.json +++ b/client/src/translations/en_us/common.json @@ -2024,7 +2024,7 @@ "joblookup": "Job Lookup", "login": "Login", "logout": "Logout", - "productionboard": "Production Board - Visual", + "productionboard": "Production Visual", "productionlist": "Production List", "shiftclockin": "Shift Clock" } @@ -2901,7 +2901,7 @@ "parts-queue": "Parts Queue | $t(titles.app)", "payments-all": "Payments | $t(titles.app)", "phonebook": "Phonebook | $t(titles.app)", - "productionboard": "Production - Board", + "productionboard": "Production Board - Visual | $t(titles.app)", "productionlist": "Production Board - List | $t(titles.app)", "profile": "My Profile | $t(titles.app)", "readyjobs": "Ready Jobs | $t(titles.app)", @@ -2913,6 +2913,10 @@ "shop-csi": "CSI Responses | $t(titles.app)", "shop-templates": "Shop Templates | $t(titles.app)", "shop_vendors": "Vendors | $t(titles.app)", + "techconsole": "Technician Console | $t(titles.app)", + "techjoblookup": "Technician Job Lookup | $t(titles.app)", + "techjobclock": "Technician Job Clock | $t(titles.app)", + "techshiftclock": "Technician Shift Clock | $t(titles.app)", "temporarydocs": "Temporary Documents | $t(titles.app)", "timetickets": "Time Tickets | $t(titles.app)", "ttapprovals": "", diff --git a/client/src/translations/es/common.json b/client/src/translations/es/common.json index da9f6b4e0..9f522ecce 100644 --- a/client/src/translations/es/common.json +++ b/client/src/translations/es/common.json @@ -2894,7 +2894,7 @@ "jobs-intake": "", "jobsavailable": "Empleos disponibles | $t(titles.app)", "jobsdetail": "Trabajo {{ro_number}} | $t(titles.app)", - "jobsdocuments": "Documentos de trabajo {{ro_number}} | $ t (títulos.app)", + "jobsdocuments": "Documentos de trabajo {{ro_number}} | $t(titles.app)", "manageroot": "Casa | $t(titles.app)", "owners": "Todos los propietarios | $t(titles.app)", "owners-detail": "", @@ -2913,6 +2913,10 @@ "shop-csi": "", "shop-templates": "", "shop_vendors": "Vendedores | $t(titles.app)", + "techconsole": "$t(titles.app)", + "techjoblookup": "$t(titles.app)", + "techjobclock": "$t(titles.app)", + "techshiftclock": "$t(titles.app)", "temporarydocs": "", "timetickets": "", "ttapprovals": "", diff --git a/client/src/translations/fr/common.json b/client/src/translations/fr/common.json index a4c1dc686..2543ae722 100644 --- a/client/src/translations/fr/common.json +++ b/client/src/translations/fr/common.json @@ -2894,7 +2894,7 @@ "jobs-intake": "", "jobsavailable": "Emplois disponibles | $t(titles.app)", "jobsdetail": "Travail {{ro_number}} | $t(titles.app)", - "jobsdocuments": "Documents de travail {{ro_number}} | $ t (titres.app)", + "jobsdocuments": "Documents de travail {{ro_number}} | $t(titles.app)", "manageroot": "Accueil | $t(titles.app)", "owners": "Tous les propriétaires | $t(titles.app)", "owners-detail": "", @@ -2913,6 +2913,10 @@ "shop-csi": "", "shop-templates": "", "shop_vendors": "Vendeurs | $t(titles.app)", + "techconsole": "$t(titles.app)", + "techjoblookup": "$t(titles.app)", + "techjobclock": "$t(titles.app)", + "techshiftclock": "$t(titles.app)", "temporarydocs": "", "timetickets": "", "ttapprovals": "",