This commit is contained in:
20
api/app/Http/Controllers/Intranet/ClienteController.php
Normal file
20
api/app/Http/Controllers/Intranet/ClienteController.php
Normal file
@@ -0,0 +1,20 @@
|
||||
<?php
|
||||
|
||||
namespace App\Http\Controllers\Intranet;
|
||||
|
||||
use App\Http\Controllers\Controller;
|
||||
use App\Models\Intranet\Cliente;
|
||||
use Illuminate\Http\Response;
|
||||
|
||||
class ClienteController extends Controller
|
||||
{
|
||||
public function index()
|
||||
{
|
||||
$cliente = $this->get(Cliente::class)
|
||||
->where('link', request()->get('link'))
|
||||
->orderBy('nome')
|
||||
->first();
|
||||
|
||||
return response()->json($cliente, Response::HTTP_OK);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user