shareneus 1.5.87 → 1.5.88
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/accounting/invoice/invoice-pdf/invoice-pdf.service.js +3 -3
- package/dist/purchases/bills/bill-pdf/bill-pdf.service.js +3 -3
- package/dist/shared/header-footer-section/pdf-header-footer.section.d.ts +2 -2
- package/dist/shared/header-footer-section/pdf-header-footer.section.js +4 -5
- package/package.json +1 -1
|
@@ -70,8 +70,8 @@ function buildPdfDocDefinition(PDFInvoiceData = {}, PrintConfigData = {}, printC
|
|
|
70
70
|
const copyLabels = normalizeCopyLabels(printCopies);
|
|
71
71
|
const watermark = (0, pdf_header_footer_section_1.buildWatermark)(PrintConfig);
|
|
72
72
|
const background = (0, pdf_header_footer_section_1.buildLogoWatermarkBackground)(PrintConfig, PDFInvoiceData);
|
|
73
|
-
const
|
|
74
|
-
const
|
|
73
|
+
const pageHeader = (0, pdf_header_footer_section_1.buildPageNumberHeader)(PrintConfig);
|
|
74
|
+
const pageFooter = (0, pdf_header_footer_section_1.buildFooter)(PrintConfig);
|
|
75
75
|
const content = [];
|
|
76
76
|
copyLabels.forEach((copyLabel, index) => {
|
|
77
77
|
const invoiceHeaderContent = (0, pdf_header_footer_section_1.buildDocumentHeaderSection)(PrintConfig, PDFInvoiceData);
|
|
@@ -112,7 +112,7 @@ function buildPdfDocDefinition(PDFInvoiceData = {}, PrintConfigData = {}, printC
|
|
|
112
112
|
const dd = Object.assign(Object.assign(Object.assign(Object.assign({ pageSize: pageSize, pageOrientation: pageOrientation, pageMargins: pageMargins, content: content, info: {
|
|
113
113
|
title: 'invoice',
|
|
114
114
|
subject: Array.isArray(printCopies) ? printCopies.join(', ') : ''
|
|
115
|
-
} }, (background ? { background } : {})), (watermark ? { watermark } : {})), (
|
|
115
|
+
} }, (background ? { background } : {})), (watermark ? { watermark } : {})), (pageHeader !== null ? { header: pageHeader } : {})), (pageFooter !== null ? { footer: pageFooter } : {}));
|
|
116
116
|
return dd;
|
|
117
117
|
}
|
|
118
118
|
function normalizeCopyLabels(printCopies = []) {
|
|
@@ -70,8 +70,8 @@ function buildPdfDocDefinition(PDFInvoiceData = {}, PrintConfigData = {}, printC
|
|
|
70
70
|
const copyLabels = normalizeCopyLabels(printCopies);
|
|
71
71
|
const watermark = (0, pdf_header_footer_section_1.buildWatermark)(PrintConfig);
|
|
72
72
|
const background = (0, pdf_header_footer_section_1.buildLogoWatermarkBackground)(PrintConfig, PDFInvoiceData);
|
|
73
|
-
const
|
|
74
|
-
const
|
|
73
|
+
const pageHeader = (0, pdf_header_footer_section_1.buildPageNumberHeader)(PrintConfig);
|
|
74
|
+
const pageFooter = (0, pdf_header_footer_section_1.buildFooter)(PrintConfig);
|
|
75
75
|
const content = [];
|
|
76
76
|
copyLabels.forEach((copyLabel, index) => {
|
|
77
77
|
const invoiceHeaderContent = (0, pdf_header_footer_section_1.buildDocumentHeaderSection)(PrintConfig, PDFInvoiceData);
|
|
@@ -112,7 +112,7 @@ function buildPdfDocDefinition(PDFInvoiceData = {}, PrintConfigData = {}, printC
|
|
|
112
112
|
const dd = Object.assign(Object.assign(Object.assign(Object.assign({ pageSize: pageSize, pageOrientation: pageOrientation, pageMargins: pageMargins, content: content, info: {
|
|
113
113
|
title: 'invoice',
|
|
114
114
|
subject: Array.isArray(printCopies) ? printCopies.join(', ') : ''
|
|
115
|
-
} }, (background ? { background } : {})), (watermark ? { watermark } : {})), (
|
|
115
|
+
} }, (background ? { background } : {})), (watermark ? { watermark } : {})), (pageHeader !== null ? { header: pageHeader } : {})), (pageFooter !== null ? { footer: pageFooter } : {}));
|
|
116
116
|
return dd;
|
|
117
117
|
}
|
|
118
118
|
function normalizeCopyLabels(printCopies = []) {
|
|
@@ -118,10 +118,10 @@ export declare function buildFooter(PrintConfig: any): (() => {
|
|
|
118
118
|
fontSize: number;
|
|
119
119
|
color: string;
|
|
120
120
|
}) | null;
|
|
121
|
-
export declare function buildPageNumberHeader(PrintConfig: any): (
|
|
121
|
+
export declare function buildPageNumberHeader(PrintConfig: any): (currentPage: number, pageCount: number) => {
|
|
122
122
|
text: string;
|
|
123
123
|
alignment: string;
|
|
124
124
|
margin: number[];
|
|
125
125
|
fontSize: number;
|
|
126
126
|
color: string;
|
|
127
|
-
}
|
|
127
|
+
};
|
|
@@ -234,11 +234,10 @@ function buildFooter(PrintConfig) {
|
|
|
234
234
|
});
|
|
235
235
|
}
|
|
236
236
|
function buildPageNumberHeader(PrintConfig) {
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
}
|
|
237
|
+
// const showPageNumber = PrintConfig?.Header?.ShowPageNumber !== false;
|
|
238
|
+
// if (!showPageNumber) {
|
|
239
|
+
// return null;
|
|
240
|
+
// }
|
|
242
241
|
return (currentPage, pageCount) => ({
|
|
243
242
|
text: `Page ${currentPage}/${pageCount}`,
|
|
244
243
|
alignment: 'right',
|