mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2024-09-20 00:11:35 +02:00
Working on API
This commit is contained in:
parent
561907ae60
commit
d42712204c
@ -13,7 +13,7 @@ return array(
|
||||
|
|
||||
*/
|
||||
|
||||
'debug' => true,
|
||||
'debug' => false,
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
|
@ -16,12 +16,16 @@ class ClientApiController extends \BaseController {
|
||||
|
||||
public function index()
|
||||
{
|
||||
$clients = Client::scope()->get()->toArray();
|
||||
$clients = Client::scope()->get();
|
||||
|
||||
return Response::json(array(
|
||||
$response = [
|
||||
'status' => 200,
|
||||
'error' => false,
|
||||
'clients' => $clients),
|
||||
200
|
||||
);
|
||||
'clients' => $clients->toArray()
|
||||
];
|
||||
|
||||
$response = json_encode($response, JSON_PRETTY_PRINT);
|
||||
|
||||
return Response::make($response, 200, ['Content-Type' => 'application/json']);
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user