Commit f7e4e263 by 杨树贤

兑现历史返回类型名称

parent d0625c27
......@@ -9,12 +9,14 @@ class UserExchangeTransformer
public function transform($data = [])
{
$types = [1 => '话费充值', 2 => '微信转账'];
if (isset($data['data'])) {
foreach ($data['data'] as $key => $value) {
$data['data'][$key] = [
'id' => array_get($value, 'id'),
'amount' => array_get($value, 'amount'),
'amount' => array_get($value, 'amount'),
'name' => array_get($value['exchange_setting'], 'name'),
'type' => $types[$value['type']],
'add_time' => array_get($value, 'add_time'),
];
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment