1234567891011121314151617 |
- <?php
- namespace App\Models;
- class PaymentMethod extends Model
- {
- protected $table = 'payment_method';
- public function customer(){
- return $this->hasOne(Customer::class, 'id', 'customer_id');
- }
- public function displayName(){
- // $parsed = json_decode($this->stripe_detail_json);
- return "Ending: <b>{$this->card_last4}</b>; Expiry: {$this->expiration_month} / {$this->expiration_year}";
- }
- }
|