BOD-9 Added print format to parts order.
This commit is contained in:
@@ -1,12 +1,11 @@
|
||||
import { MailOutlined, PrinterOutlined } from "@ant-design/icons";
|
||||
import React from "react";
|
||||
import { connect } from "react-redux";
|
||||
import { createStructuredSelector } from "reselect";
|
||||
import { setEmailOptions } from "../../redux/email/email.actions";
|
||||
import { selectPrintCenter } from "../../redux/modals/modals.selectors";
|
||||
import { selectBodyshop } from "../../redux/user/user.selectors";
|
||||
import { MailOutlined, PrinterOutlined } from "@ant-design/icons";
|
||||
import RenderTemplate from "../../utils/RenderTemplate";
|
||||
import { useApolloClient } from "@apollo/react-hooks";
|
||||
const mapStateToProps = createStructuredSelector({
|
||||
printCenterModal: selectPrintCenter,
|
||||
bodyshop: selectBodyshop,
|
||||
@@ -23,15 +22,13 @@ export function PrintCenterItemComponent({
|
||||
bodyshop,
|
||||
disabled,
|
||||
}) {
|
||||
const client = useApolloClient();
|
||||
|
||||
const renderToNewWindow = async () => {
|
||||
const html = await RenderTemplate(
|
||||
{
|
||||
name: item.key,
|
||||
variables: { id: id },
|
||||
},
|
||||
client,
|
||||
|
||||
bodyshop
|
||||
);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user