Feat: Adds multi currency support to API (#90)
This commit is contained in:
@@ -21,6 +21,7 @@ class HoldingResource extends JsonResource
|
||||
'portfolio_id' => $this->portfolio_id,
|
||||
'symbol' => $this->symbol,
|
||||
'quantity' => $this->quantity,
|
||||
'currency' => $this->market_data->currency,
|
||||
'reinvest_dividends' => $this->reinvest_dividends,
|
||||
'average_cost_basis' => $this->average_cost_basis,
|
||||
'total_cost_basis' => $this->total_cost_basis,
|
||||
|
||||
@@ -22,6 +22,7 @@ class TransactionResource extends JsonResource
|
||||
'portfolio_id' => $this->portfolio_id,
|
||||
'transaction_type' => $this->transaction_type,
|
||||
'quantity' => $this->quantity,
|
||||
'currency' => $this->market_data->currency,
|
||||
'cost_basis' => $this->cost_basis,
|
||||
'sale_price' => $this->sale_price,
|
||||
'split' => $this->split,
|
||||
|
||||
@@ -22,6 +22,10 @@ class UserResource extends JsonResource
|
||||
'name' => $this->name,
|
||||
'email' => $this->email,
|
||||
'profile_photo_url' => $this->profile_photo_url,
|
||||
'options' => [
|
||||
'display_currency' => $this->getCurrency(),
|
||||
'locale' => $this->getLocale(),
|
||||
],
|
||||
'created_at' => $this->created_at,
|
||||
'updated_at' => $this->updated_at,
|
||||
];
|
||||
|
||||
Reference in New Issue
Block a user