refactoring of deal documents
This commit is contained in:
@@ -259,7 +259,7 @@ const Content: FC<Props> = ({ deal }) => {
|
||||
<ActionIcon
|
||||
onClick={() => {
|
||||
const pdfWindow = window.open(
|
||||
`${import.meta.env.VITE_API_URL}/deal/detailedDocument/${deal.id}`,
|
||||
`${import.meta.env.VITE_API_URL}/deal/tech-spec/${deal.id}`,
|
||||
);
|
||||
if (!pdfWindow) return;
|
||||
pdfWindow.print();
|
||||
@@ -284,7 +284,7 @@ const Content: FC<Props> = ({ deal }) => {
|
||||
const date =
|
||||
getCurrentDateTimeForFilename();
|
||||
FileSaver.saveAs(
|
||||
`${import.meta.env.VITE_API_URL}/deal/document/${deal.id}`,
|
||||
`${import.meta.env.VITE_API_URL}/deal/billing-document/${deal.id}`,
|
||||
`bill_${deal.id}_${date}.pdf`,
|
||||
);
|
||||
}}
|
||||
|
||||
Reference in New Issue
Block a user