Lint all the things
This commit is contained in:
@@ -101,12 +101,12 @@ export function JobChecklistForm({ insertAuditTrail, formItems, bodyshop, curren
|
||||
}
|
||||
}
|
||||
});
|
||||
if (!!search.appointmentId) {
|
||||
if (search.appointmentId) {
|
||||
const appUpdate = await markAptArrived({
|
||||
variables: { appointmentId: search.appointmentId }
|
||||
});
|
||||
|
||||
if (!!appUpdate.errors) {
|
||||
if (appUpdate.errors) {
|
||||
notification["error"]({
|
||||
message: t("checklist.errors.complete", {
|
||||
error: JSON.stringify(result.errors)
|
||||
@@ -118,7 +118,7 @@ export function JobChecklistForm({ insertAuditTrail, formItems, bodyshop, curren
|
||||
variables: { jobId: jobId }
|
||||
});
|
||||
|
||||
if (!!appUpdate.errors) {
|
||||
if (appUpdate.errors) {
|
||||
notification["error"]({
|
||||
message: t("checklist.errors.complete", {
|
||||
error: JSON.stringify(result.errors)
|
||||
@@ -129,7 +129,7 @@ export function JobChecklistForm({ insertAuditTrail, formItems, bodyshop, curren
|
||||
|
||||
setLoading(false);
|
||||
|
||||
if (!!!result.errors) {
|
||||
if (!result.errors) {
|
||||
notification["success"]({ message: t("checklist.successes.completed") });
|
||||
history(`/manage/jobs/${jobId}`);
|
||||
|
||||
@@ -137,6 +137,7 @@ export function JobChecklistForm({ insertAuditTrail, formItems, bodyshop, curren
|
||||
jobid: jobId,
|
||||
operation: AuditTrailMapping.jobchecklist(
|
||||
type,
|
||||
// eslint-disable-next-line no-constant-binary-expression
|
||||
(type === "deliver" && values.removeFromProduction && false) || (type === "intake" && values.addToProduction),
|
||||
(type === "intake" && bodyshop.md_ro_statuses.default_arrived) ||
|
||||
(type === "deliver" && bodyshop.md_ro_statuses.default_delivered)
|
||||
|
||||
@@ -1,12 +1,13 @@
|
||||
import { PrinterFilled } from "@ant-design/icons";
|
||||
import { Button, Card, List } from "antd";
|
||||
import React, { useState } from "react";
|
||||
import { useState } from "react";
|
||||
import { useTranslation } from "react-i18next";
|
||||
import { useParams } from "react-router-dom";
|
||||
import { logImEXEvent } from "../../../../firebase/firebase.utils";
|
||||
import { GenerateDocument, GenerateDocuments } from "../../../../utils/RenderTemplate";
|
||||
import { TemplateList } from "../../../../utils/TemplateConstants";
|
||||
import { useNotification } from "../../../../contexts/Notifications/notificationContext.jsx";
|
||||
|
||||
const TemplateListGenerated = TemplateList();
|
||||
|
||||
export default function JobIntakeTemplateList({ templates }) {
|
||||
@@ -60,7 +61,7 @@ export default function JobIntakeTemplateList({ templates }) {
|
||||
renderItem={(template) => (
|
||||
<List.Item
|
||||
actions={[
|
||||
<Button loading={loading} onClick={() => renderTemplate(template)}>
|
||||
<Button key="checkListTemplateButton" loading={loading} onClick={() => renderTemplate(template)}>
|
||||
<PrinterFilled />
|
||||
</Button>
|
||||
]}
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
import React from "react";
|
||||
import ConfigFormComponents from "../config-form-components/config-form-components.component";
|
||||
|
||||
export default function JobChecklistDisplay({ checklist }) {
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
import React from "react";
|
||||
import JobChecklistTemplateList from "./components/job-checklist-template-list/job-checklist-template-list.component";
|
||||
import JobChecklistForm from "./components/job-checklist-form/job-checklist-form.component";
|
||||
import { Col, Row } from "antd";
|
||||
|
||||
Reference in New Issue
Block a user