diff --git a/global_business/business/views/api/v1/transactions/show.json.jbuilder b/global_business/business/views/api/v1/transactions/show.json.jbuilder new file mode 100644 index 000000000..bc291e835 --- /dev/null +++ b/global_business/business/views/api/v1/transactions/show.json.jbuilder @@ -0,0 +1,12 @@ +json.extract! @transaction, :id, :amount, :transaction_type, :created_at +json.account do + json.extract! @transaction.account, :id, :account_number, :routing_number +end +json.user do + json.extract! @transaction.account.user, :id, :username, :email +end +json.category do + json.extract! @transaction.category, :id, :name +end +json.receipt_url @transaction.receipt_url +json.transaction_status @transaction.transaction_status