Compare commits

..

4 Commits

Author SHA1 Message Date
Patrick Fic
82fbe74723 Merge branch 'rome/release/2024-03-01' into rome/test 2024-03-04 08:13:51 -05:00
Patrick Fic
929854fd55 Merge branch 'rome/release/2024-02-16' into rome/test 2024-02-20 13:37:15 -08:00
Patrick Fic
6187b19e91 Merge branch 'rome/release/2024-02-16' into rome/test 2024-02-20 13:33:54 -08:00
Patrick Fic
89bc11e4ad Merge branch 'rome/release/2024-02-09' into rome/test 2024-02-12 13:24:58 -08:00
6 changed files with 24 additions and 30 deletions

View File

@@ -21,13 +21,7 @@ export function DmsCdkMakesRefetch({ currentUser, bodyshop, form, socket }) {
const [loading, setLoading] = useState(false);
const { t } = useTranslation();
if (
!(
currentUser.email.includes("@imex.") ||
currentUser.email.includes("@rome.")
)
)
return null;
if (!currentUser.email.includes("@imex.")) return null;
const handleRefetch = async () => {
setLoading(true);

View File

@@ -18,8 +18,8 @@ const sortByParentId = (arr) => {
//console.log("sortByParentId -> byParentsIdsList", byParentsIdsList);
while (byParentsIdsList[parentId]) {
sortedList.push(...byParentsIdsList[parentId]); //Spread in the whole list in case several items have the same parents.
parentId = byParentsIdsList[parentId][byParentsIdsList[parentId].length -1].id; //Grab the ID from the last one.
sortedList.push(byParentsIdsList[parentId][0]);
parentId = byParentsIdsList[parentId][0].id;
}
if (byParentsIdsList["null"])

View File

@@ -1,23 +1,24 @@
import { useLazyQuery } from "@apollo/client";
import {useLazyQuery} from "@apollo/client";
import { useTreatments } from "@splitsoftware/splitio-react";
import { Button, Card, Col, DatePicker, Form, Input, Radio, Row, Typography, } from "antd";
import {Button, Card, Col, DatePicker, Form, Input, Radio, Row, Typography,} from "antd";
import _ from "lodash";
import moment from "moment";
import React, { useState } from "react";
import { useTranslation } from "react-i18next";
import { connect } from "react-redux";
import { createStructuredSelector } from "reselect";
import { QUERY_ACTIVE_EMPLOYEES } from "../../graphql/employees.queries";
import { QUERY_ALL_VENDORS } from "../../graphql/vendors.queries";
import { selectReportCenter } from "../../redux/modals/modals.selectors";
import React, {useState} from "react";
import {useTranslation} from "react-i18next";
import {connect} from "react-redux";
import {createStructuredSelector} from "reselect";
import {QUERY_ACTIVE_EMPLOYEES} from "../../graphql/employees.queries";
import {QUERY_ALL_VENDORS} from "../../graphql/vendors.queries";
import {selectReportCenter} from "../../redux/modals/modals.selectors";
import { selectBodyshop } from "../../redux/user/user.selectors";
import DatePickerRanges from "../../utils/DatePickerRanges";
import { GenerateDocument } from "../../utils/RenderTemplate";
import { TemplateList } from "../../utils/TemplateConstants";
import {GenerateDocument} from "../../utils/RenderTemplate";
import {TemplateList} from "../../utils/TemplateConstants";
import EmployeeSearchSelect from "../employee-search-select/employee-search-select.component";
import VendorSearchSelect from "../vendor-search-select/vendor-search-select.component";
import ReportCenterModalFiltersSortersComponent from "./report-center-modal-filters-sorters-component";
import "./report-center-modal.styles.scss";
import ReportCenterModalFiltersSortersComponent from "./report-center-modal-filters-sorters-component";
import {selectBodyshop} from "../../redux/user/user.selectors";
const mapStateToProps = createStructuredSelector({
reportCenterModal: selectReportCenter,

View File

@@ -75,18 +75,17 @@ exports.default = async function ReloadCdkMakes(req, res) {
);
res.sendStatus(200);
} catch (error) {
console.log("Error inserting CDK Vehicles.", error)
logger.log(
"cdk-replace-makes-models-error",
"ERROR",
req.user.email,
null,
{CDK_CREDENTIALS,
{
cdk_dealerid,
error: error.message,
error,
}
);
res.status(500).json(error.message);
res.status(500).json(error);
}
};
@@ -142,10 +141,8 @@ async function GetCdkMakes(req, cdk_dealerid) {
req.user.email,
null,
{
CDK_CREDENTIALS,
cdk_dealerid,
error,
request: JSON.stringify(error.request)
}
);

View File

@@ -600,7 +600,11 @@ async function InsertDmsCustomer(socket, newCustomerNumber) {
socket.JobData.ownr_ctry &&
socket.JobData.ownr_ctry.replace(replaceSpecialRegex, ""),
postalCode:
socket.JobData.ownr_zip,
socket.JobData.ownr_zip &&
socket.JobData.ownr_zip //TODO Need to remove for US Based customers.
.toUpperCase()
.replace(/\W/g, "")
.replace(/(...)/, "$1 "),
stateOrProvince:
socket.JobData.ownr_st &&
socket.JobData.ownr_st.replace(replaceSpecialRegex, ""),

View File

@@ -1,7 +1,6 @@
const express = require('express');
const router = express.Router();
const job = require('../job/job');
const ppc = require('../ccc/partspricechange')
const {partsScan} = require('../parts-scan/parts-scan');
const eventAuthorizationMiddleware = require('../middleware/eventAuthorizationMIddleware');
const validateFirebaseIdTokenMiddleware = require("../middleware/validateFirebaseIdTokenMiddleware");
@@ -15,6 +14,5 @@ router.post('/costing', validateFirebaseIdTokenMiddleware, withUserGraphQLClient
router.post('/lifecycle', validateFirebaseIdTokenMiddleware, withUserGraphQLClientMiddleware, lifecycle);
router.post('/costingmulti', validateFirebaseIdTokenMiddleware, withUserGraphQLClientMiddleware, costingmulti);
router.post('/partsscan', validateFirebaseIdTokenMiddleware, withUserGraphQLClientMiddleware, partsScan);
router.post('/ppc', validateFirebaseIdTokenMiddleware, withUserGraphQLClientMiddleware, ppc.generatePpc);
module.exports = router;