Pārlūkot izejas kodu

[Espace producteur] Mes commandes : libellé paiement commandes #1266

feature/souke
Guillaume Bourgeois pirms 1 gada
vecāks
revīzija
a6d5a31682
1 mainītis faili ar 1 papildinājumiem un 22 dzēšanām
  1. +1
    -22
      common/logic/Order/Order/Repository/OrderRepository.php

+ 1
- 22
common/logic/Order/Order/Repository/OrderRepository.php Parādīt failu

@@ -240,29 +240,8 @@ class OrderRepository extends AbstractRepository
public function getAmountSummary(Order $order): string
{
$html = '';
$creditActive = $this->producerSolver->getConfig('credit');
$html .= $this->orderSolver->getOrderAmountWithTax($order, Order::AMOUNT_TOTAL, true);

if ($creditActive) {
$html .= '<br />';
if ($order->paid_amount) {
if ($this->orderSolver->getPaymentStatus($order) == Order::PAYMENT_PAID) {
$html .= '<span class="label label-success">Payée</span>';
} elseif ($this->orderSolver->getPaymentStatus($order) == Order::PAYMENT_UNPAID) {
$html .= '<span class="label label-danger">Non payée</span><br />
Reste <strong>' . $this->orderSolver->getOrderAmount(
$order,
Order::AMOUNT_REMAINING,
true
) . '</strong> à payer';
} elseif ($this->orderSolver->getPaymentStatus($order) == Order::PAYMENT_SURPLUS) {
$html .= '<span class="label label-success">Payée</span>';
}
} else {
$html .= '<span class="label label-default">Non réglé</span>';
}
}

$html .= '<br />'.$this->getPaymentLabelShort($order);
return $html;
}


Notiek ielāde…
Atcelt
Saglabāt