Lint all the things

This commit is contained in:
Dave
2025-08-19 16:23:29 -04:00
parent f6d6b548be
commit 33fb60ca1a
640 changed files with 2129 additions and 3927 deletions

View File

@@ -1,19 +1,12 @@
import { Form, Select } 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({
//currentUser: selectCurrentUser
bodyshop: selectBodyshop
});
const mapDispatchToProps = (dispatch) => ({
//setUserLanguage: language => dispatch(setUserLanguage(language))
});
const mapStateToProps = createStructuredSelector({});
const mapDispatchToProps = () => ({});
export function TimeTicketShiftFormComponent({ bodyshop, form }) {
export function TimeTicketShiftFormComponent() {
const { t } = useTranslation();
return (
<div>

View File

@@ -2,7 +2,7 @@ import { useMutation } from "@apollo/client";
import { Button, Form, Space } from "antd";
import axios from "axios";
import dayjs from "../../utils/day";
import React, { useMemo, useState } from "react";
import { useMemo, useState } from "react";
import { useTranslation } from "react-i18next";
import { connect } from "react-redux";
import { createStructuredSelector } from "reselect";
@@ -18,7 +18,7 @@ const mapStateToProps = createStructuredSelector({
bodyshop: selectBodyshop,
technician: selectTechnician
});
const mapDispatchToProps = (dispatch) => ({
const mapDispatchToProps = () => ({
//setUserLanguage: language => dispatch(setUserLanguage(language))
});
@@ -33,7 +33,7 @@ export function TimeTicektShiftContainer({ bodyshop, technician, currentUser, is
const employeeId = useMemo(() => {
const assoc = bodyshop.associations.filter((a) => a.useremail === currentUser.email)[0];
return assoc && assoc.user && assoc.user.employee && assoc.user.employee.id;
return assoc?.user && assoc.user.employee && assoc.user.employee.id;
}, [bodyshop, currentUser.email]);
const handleFinish = async (values) => {
@@ -80,7 +80,7 @@ export function TimeTicektShiftContainer({ bodyshop, technician, currentUser, is
refetchQueries: ["QUERY_ACTIVE_SHIFT_TIME_TICKETS"]
});
if (!!result.errors) {
if (result.errors) {
notification["error"]({
message: t("timetickets.errors.clockingin", {
message: JSON.stringify(result.errors)