1
0
mirror of https://github.com/invoiceninja/invoiceninja.git synced 2024-11-11 21:52:35 +01:00
invoiceninja/app/Ninja/Transformers/InvoiceItemTransformer.php
2015-11-03 16:21:17 +02:00

16 lines
372 B
PHP

<?php namespace App\Ninja\Transformers;
use App\Models\InvoiceItem;
use League\Fractal;
use League\Fractal\TransformerAbstract;
class InvoiceItemTransformer extends TransformerAbstract
{
public function transform(InvoiceItem $item)
{
return [
'id' => (int) $item->public_id,
'product_key' => $item->product_key,
];
}
}