@bookipi/htmlgenerator 1.1.46-alpha5 → 1.1.46-alpha6
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/index.js +4 -4
- package/dist/index.js.map +1 -1
- package/dist/index.modern.js +4 -4
- package/dist/index.modern.js.map +1 -1
- package/package.json +1 -1
package/dist/index.modern.js
CHANGED
|
@@ -12895,15 +12895,15 @@ var subscriptionInvoiceHtml = (function (_ref) {
|
|
|
12895
12895
|
});
|
|
12896
12896
|
if (discountItems.length === 0) {
|
|
12897
12897
|
discountItems = productItems.map(function (item) {
|
|
12898
|
-
return
|
|
12898
|
+
return {
|
|
12899
12899
|
type: 'discount',
|
|
12900
12900
|
name: 'Previous subscription discount',
|
|
12901
|
-
total: item.discount
|
|
12902
|
-
}
|
|
12901
|
+
total: item.discount || 0
|
|
12902
|
+
};
|
|
12903
12903
|
});
|
|
12904
12904
|
}
|
|
12905
12905
|
var renderDiscount = function renderDiscount(discountItem) {
|
|
12906
|
-
if (!discountItem) {
|
|
12906
|
+
if (!discountItem || discountItem.total === 0) {
|
|
12907
12907
|
return '';
|
|
12908
12908
|
}
|
|
12909
12909
|
return "<div class=\"invoice-order-item\">\n <div class=\"invoice-order-details\">\n <div>\n <div class=\"invoice-spacing invoice-body3\">" + discountItem.name + "</div>\n </div>\n <div style=\"font-size:16px;color:#C81E1E;\">\n -" + formatPrice(discountItem.total, currency) + "\n </div>\n </div>\n </div>";
|