forked from qwerty/milfs
24 lines
557 B
PHP
24 lines
557 B
PHP
<?php
|
|
use \Psr\Http\Message\ServerRequestInterface as Request;
|
|
use \Psr\Http\Message\ResponseInterface as Response;
|
|
|
|
$app =new \Slim\app;
|
|
// aplicaicon por id
|
|
$app ->get('/api/aplicaciones/{id}', function(Request $request, Response $response){
|
|
$datos= array();
|
|
$datos['id']= $request->getAttribute('id');
|
|
$datos['tipo']='simple';
|
|
|
|
echo json($datos);
|
|
|
|
});
|
|
// todas las aplicaciones
|
|
$app ->get('/api/aplicaciones/', function(Request $request, Response $response){
|
|
|
|
$datos= array();
|
|
$datos['id']= '';
|
|
$datos['tipo']='simple';
|
|
echo json('');
|
|
|
|
});
|