0
0
Files
Babyclass/app/Api/Resources/WithdrawLogsResource.php
2020-08-04 10:09:42 +08:00

33 lines
761 B
PHP

<?php
/**
* Created by PhpStorm.
* User: sunny
* Date: 2019/2/26
* Time: 2:51 PM
*/
namespace App\Api\Resources;
use Illuminate\Http\Resources\Json\JsonResource;
class WithdrawLogsResource extends JsonResource
{
/**
* 小程序,提现日志返回的数据
*
* @param \Illuminate\Http\Request $request
* @return array
*/
public function toArray($request)
{
return [
'id' => $this->id,
'state_text' => $this->state_text,
'created_at' => $this->created_at,
'amount' =>number_format($this->amount,2),
'take' =>number_format($this->take,2),
'tax' =>number_format($this->tax,2),
'way_text' =>$this->way_text,
];
}
}