IO-233 Export Job Refactor

This commit is contained in:
Patrick Fic
2021-08-23 19:02:05 -07:00
parent 3ca6791939
commit 6c12e5cb03
4 changed files with 371 additions and 297 deletions

View File

@@ -7,6 +7,7 @@ import { useTranslation } from "react-i18next";
import { useLazyQuery } from "@apollo/client";
import { SEARCH_DMS_VEHICLES } from "../../graphql/dms.queries";
import AlertComponent from "../alert/alert.component";
const mapStateToProps = createStructuredSelector({
//currentUser: selectCurrentUser
bodyshop: selectBodyshop,

View File

@@ -277,6 +277,15 @@ export function DmsPostForm({ bodyshop, socket, job }) {
<Button disabled={discrep.getAmount() !== 0} htmlType="submit">
{t("jobs.actions.dms.post")}
</Button>
<Button
onClick={() => {
socket.emit(`${determineDmsType(bodyshop)}-export-job`, {
jobid: job.id,
});
}}
>
Bypass
</Button>
</Space>
);
}}