shareneus 1.4.20 → 1.4.22
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.
|
@@ -38,6 +38,8 @@ class InvoicePortraitPrintService {
|
|
|
38
38
|
},
|
|
39
39
|
this.GetItemsTable(InvoicePDFData.Ops, InvoicePDFData.Items, InvoicePDFData.ShowTaxColumn, InvoicePDFData.SType, printOptions, size),
|
|
40
40
|
[this.TotalDetails(InvoicePDFData)],
|
|
41
|
+
[this.InvoiceDueStatus(InvoicePDFData.Type, InvoicePDFData.Paid, InvoicePDFData.Due, InvoicePDFData.Sts, InvoicePDFData.isCountersale),
|
|
42
|
+
],
|
|
41
43
|
{
|
|
42
44
|
style: 'tableExample',
|
|
43
45
|
table: {
|
|
@@ -90,6 +92,36 @@ class InvoicePortraitPrintService {
|
|
|
90
92
|
};
|
|
91
93
|
return dd;
|
|
92
94
|
}
|
|
95
|
+
static LayOutStyle() {
|
|
96
|
+
return {
|
|
97
|
+
hLineColor: function (i, node) {
|
|
98
|
+
return (i === 0 || i === 1 || i === 2 || i === node.table.body.length) ? 'gray' : 'white';
|
|
99
|
+
},
|
|
100
|
+
vLineColor: function (i, node) {
|
|
101
|
+
return (i === 0 || i === node.table.widths.length) ? 'gray' : 'white';
|
|
102
|
+
}
|
|
103
|
+
};
|
|
104
|
+
}
|
|
105
|
+
static InvoiceDueStatus(Type, Paid, Due, Status, isCounter) {
|
|
106
|
+
if (Type === 'Invoice' && !isCounter) {
|
|
107
|
+
return {
|
|
108
|
+
// lineHeight: 0.7,
|
|
109
|
+
fontSize: this.TableHeaders,
|
|
110
|
+
marginTop: 10,
|
|
111
|
+
marginBottom: 5,
|
|
112
|
+
table: {
|
|
113
|
+
widths: ['*', '*', '*'],
|
|
114
|
+
body: [[{ text: 'Paid : ' + Paid },
|
|
115
|
+
{ text: 'Due : ' + Due },
|
|
116
|
+
{ text: 'Status : ' + Status }]]
|
|
117
|
+
},
|
|
118
|
+
layout: this.LayOutStyle(),
|
|
119
|
+
};
|
|
120
|
+
}
|
|
121
|
+
else {
|
|
122
|
+
return this.emptyObject();
|
|
123
|
+
}
|
|
124
|
+
}
|
|
93
125
|
static GetMainHeaderInfo(InvoicePDFData) {
|
|
94
126
|
if (!tr_utils_1.TrUtils.IsNull(InvoicePDFData.Image)) {
|
|
95
127
|
return {
|
|
@@ -754,3 +786,4 @@ class InvoicePortraitPrintService {
|
|
|
754
786
|
}
|
|
755
787
|
}
|
|
756
788
|
exports.InvoicePortraitPrintService = InvoicePortraitPrintService;
|
|
789
|
+
InvoicePortraitPrintService.TableHeaders = 9;
|