Skip to content

Commit

Permalink
NTR: fix missing no-composition display in refund manager
Browse files Browse the repository at this point in the history
  • Loading branch information
boxblinkracer committed Sep 28, 2023
1 parent 544d1aa commit c9cfc77
Showing 1 changed file with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ Component.register('mollie-refund-manager', {
pendingRefunds: 0,
checkVerifyRefund: false,
refundDescription: '',
refundInternalDescription:'',
refundInternalDescription: '',
roundingDiff: 0,
// -------------------------------
// tutorials
Expand Down Expand Up @@ -128,8 +128,8 @@ Component.register('mollie-refund-manager', {
* Return the title with a count
* @returns {*}
*/
descriptionCharacterCountingTitle(){
return this.$tc('mollie-payments.refund-manager.summary.lblDescription',0,{characters:this.refundDescription.length})
descriptionCharacterCountingTitle() {
return this.$tc('mollie-payments.refund-manager.summary.lblDescription', 0, {characters: this.refundDescription.length})
},

},
Expand Down Expand Up @@ -491,7 +491,7 @@ Component.register('mollie-refund-manager', {

getRefundCompositions(item) {

if (!item || !item.metadata || !item.metadata.composition) {
if (!item || !item.metadata || !item.metadata.composition || item.metadata.composition.length <= 0) {
return [
this.$tc('mollie-payments.refund-manager.refunds.grid.lblNoComposition'),
];
Expand All @@ -502,7 +502,7 @@ Component.register('mollie-refund-manager', {

item.metadata.composition.forEach(function (entry) {
let label = entry.label;
if(entry.swReference.length > 0){
if (entry.swReference.length > 0) {
label = entry.swReference;
}
result.push(label + ' (' + entry.quantity + ' x ' + entry.amount + ' ' + me.order.currency.symbol + ')');
Expand Down

0 comments on commit c9cfc77

Please sign in to comment.