Commit fa8706cf2e7a9bf7604a9382a2ae26928443a047

Authored by André Souza
1 parent 89f576f6
Exists in master and in 1 other branch desenv

Adicionando WS para buscar órgãos para assinatura de documentos

Showing 1 changed file with 13 additions and 0 deletions   Show diff stats
controlador_ws.php
... ... @@ -442,6 +442,19 @@ $app->group('/api/v1',function(){
442 442 }
443 443 return $response->withJSON($rn->listarAssinante($dto));
444 444 });
  445 +
  446 + $this->get('/orgao', function($request, $response, $args){
  447 + /** @var $request Slim\Http\Request */
  448 + $rn = new MdWsSeiOrgaoRN();
  449 + $dto = new OrgaoDTO();
  450 + if($request->getParam('limit')){
  451 + $dto->setNumMaxRegistrosRetorno($request->getParam('limit'));
  452 + }
  453 + if(!is_null($request->getParam('start'))){
  454 + $dto->setNumPaginaAtual($request->getParam('start'));
  455 + }
  456 + return $response->withJSON($rn->listarOrgao($dto));
  457 + });
445 458  
446 459 })->add( new TokenValidationMiddleware());
447 460  
... ...