我有一个这样的对象,里面有一个数组:
Abc Object
(
[attributes:protected] => Array
(
[id] => xx
[entity] => payment
[amount] => 1475047
[order_id] =>
[invoice_id] =>
[created_at] => 1558350389
)
)
如何从中获取id
,entity
,amount
,invoice_id
,order_id
作为对象?
修改 调用外部API:
$api = new Api($dbres[0]['api_key'], $dbres[0]['secret_key']);
$payment = $api->payment->fetch($validationObj['paymentReference']);
$respObj = $payment->capture(array('amount' => $validationObj['amount'])) ;
print_r($respObj);exit;