2023-06-26 17:41:00 +02:00
|
|
|
<?php
|
|
|
|
|
|
|
|
namespace D3\GoogleAnalytics4\Modules\Application\Model;
|
|
|
|
|
|
|
|
use OxidEsales\Eshop\Application\Model\Payment;
|
|
|
|
|
|
|
|
class Basket extends Basket_parent
|
|
|
|
{
|
|
|
|
/**
|
2024-01-17 15:36:43 +01:00
|
|
|
* @return string
|
2023-06-26 17:41:00 +02:00
|
|
|
*/
|
2024-11-25 18:48:39 +01:00
|
|
|
public function getPaymentOnPaymentId(): string
|
2023-06-26 17:41:00 +02:00
|
|
|
{
|
2024-11-25 18:48:39 +01:00
|
|
|
if ($this->getPaymentId()) {
|
2023-06-26 17:41:00 +02:00
|
|
|
$oPayment = oxNew(Payment::class);
|
2024-11-25 18:48:39 +01:00
|
|
|
if ($oPayment->load($this->getPaymentId())) {
|
2023-06-26 17:41:00 +02:00
|
|
|
return $oPayment->getFieldData('oxdesc');
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
return "couldn't load payment!";
|
|
|
|
}
|
2024-11-25 18:48:39 +01:00
|
|
|
}
|