Merge pull request #564 from turbo124/master

Working on API
This commit is contained in:
David Bomba 2015-12-15 22:05:37 +11:00
commit aca1d40a8a
2 changed files with 5 additions and 2 deletions

View File

@ -13,8 +13,8 @@ class InvoiceItemTransformer extends EntityTransformer
'product_key' => $item->product_key, 'product_key' => $item->product_key,
'account_key' => $this->account->account_key, 'account_key' => $this->account->account_key,
'user_id' => (int) $item->user_id, 'user_id' => (int) $item->user_id,
'invoice_id' => (int) $item->invoice_id, 'invoice_id' => (int) $item->invoice->public_id,
'product_id' => (int) $item->product_id, 'product_id' => (int) $item->product->public_id,
'updated_at' => $item->updated_at, 'updated_at' => $item->updated_at,
'deleted_at' => $item->deleted_at, 'deleted_at' => $item->deleted_at,
'product_key' => $item->product_key, 'product_key' => $item->product_key,

View File

@ -13,6 +13,9 @@ class ProductTransformer extends EntityTransformer
'notes' => $product->notes, 'notes' => $product->notes,
'cost' => $product->cost, 'cost' => $product->cost,
'qty' => $product->qty, 'qty' => $product->qty,
'account_key' =>$this->account->account_key,
'default_tax_rate_id' =>$product->default_tax_rate_id,
'updated_at' =>$product->updated_at,
]; ];
} }
} }