Commit 67d9264c authored by Karamel's avatar Karamel
Browse files

Add legacy compatibility on TicketPayment->toStruct for desktop.

parent e2cc76fc
......@@ -152,4 +152,13 @@ class TicketPayment extends DoctrineModel // Embedded class
// And this is the normal case
return parent::fromStruct($struct, $dao, $embedded);
public function toStruct() {
$struct = parent::toStruct();
// Add 'type' for compatibility with Desktop
// which doesn't use PaymentMode.
$struct['type'] = $this->getPaymentMode()->getReference();
return $struct;
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment