'integer', 'reminder_date' => 'datetime', ]; public function shopping_order() { return $this->belongsTo('App\Models\ShoppingOrder','shopping_order_id'); } public function payment_transactions() { return $this->hasMany('App\Models\PaymentTransaction','shopping_payment_id'); } public function getPaymentType(){ if($this->clearingtype === 'pp') { return 'PayPal'; } if($this->clearingtype === 'cc') { return 'Kreditkarte'; } if($this->clearingtype === 'vor') { return 'Vorkasse'; } if($this->clearingtype === 'elv') { return 'SEPA Lastschrift'; } if($this->clearingtype === 'sb') { return 'Sofort Überweisung'; } if($this->clearingtype === 'fnc') { return 'Rechnung'; } if($this->clearingtype === 'non') { return 'keine'; } return 'keine'; } public function getPaymentAmount(){ return Util::formatNumber($this->amount/100)." ".$this->currency; } }