sarga/packages/Webkul/API/Http/Resources/Checkout/CartPayment.php

25 lines
641 B
PHP
Raw Normal View History

2019-05-07 11:36:21 +00:00
<?php
namespace Webkul\API\Http\Resources\Checkout;
use Illuminate\Http\Resources\Json\JsonResource;
class CartPayment extends JsonResource
{
/**
* Transform the resource into an array.
*
* @param \Illuminate\Http\Request
* @return array
*/
public function toArray($request)
{
return [
2020-02-19 11:24:04 +00:00
'id' => $this->id,
'method' => $this->method,
2019-05-07 11:36:21 +00:00
'method_title' => core()->getConfigData('sales.paymentmethods.' . $this->method . '.title'),
2020-02-19 11:24:04 +00:00
'created_at' => $this->created_at,
'updated_at' => $this->updated_at
2019-05-07 11:36:21 +00:00
];
}
}