CASH-133 cart cleanup
This commit is contained in:
Johnny shultz 2025-04-01 11:39:18 -04:00
parent 383eb001df
commit decb75c369

View file

@ -207,7 +207,6 @@ export default {
isNoComp: Boolean,
isExpandedOnLoad: Boolean,
isMSRFeeApplicable: Boolean,
donationAmount: Number,
},
data() {
return {
@ -1072,7 +1071,10 @@ export default {
return promoCartItems;
},
showDonationCartItem() {
if (this.donationAmount !== 0) {
const donationLineItem = this.lineItems.supportingItems.find(
(item) => item.partType === partTypeStrings.DONATION
);
if (donationLineItem?.sellingPrice !== 0) {
return true;
} else {
return false;
@ -1090,7 +1092,7 @@ export default {
(item) => item.partType === partTypeStrings.DONATION
);
if (donationLineItem && donationLineItem.sellingPrice > 0) {
if (donationLineItem?.sellingPrice > 0) {
return {
name: this.donationCartItemName,
category: cartItemCategories.SUPPORTING_ITEMS,