D7net
Home
Console
Upload
information
Create File
Create Folder
About
Tools
:
/
var
/
www
/
html
/
idoso
/
adm
/
app
/
gre
/
Controllers
/
Filename :
ServicoContratado.php
back
Copy
<?php namespace App\gre\Controllers; if (!defined('URL')) { header("Location: /"); exit(); } /** * Description of ServicoContratado * * @copyright (c) year, Carlos Marques - CM */ class ServicoContratado { private $Dados; private $DadosForm; private $PageId; public function listar($PageId = null) { $botao = ['list_serv_contr' => ['menu_controller' => 'servico-contratado', 'menu_metodo' => 'listar'], 'cad_serv_contr' => ['menu_controller' => 'cadastrar-servico-residente', 'menu_metodo' => 'cad-serv-resid'], 'vis_serv_contr' => ['menu_controller' => 'listar-servico-residente', 'menu_metodo' => 'list-serv-resid'], 'edit_serv_contr' => ['menu_controller' => 'editar-servico-contratado', 'menu_metodo' => 'edit-serv-contr'], 'del_serv_contr' => ['menu_controller' => 'apagar-serv-contratado', 'menu_metodo' => 'apagar-serv-contr']]; $listarBotao = new \App\adms\Models\AdmsBotao(); $this->Dados['botao'] = $listarBotao->valBotao($botao); $listarMenu = new \App\adms\Models\AdmsMenu(); $this->Dados['menu'] = $listarMenu->itemMenu(); $this->DadosForm = filter_input_array(INPUT_POST, FILTER_DEFAULT); if (!empty($this->DadosForm['PesqServContr'])) { unset($this->DadosForm['PesqServContr']); } else { $this->PageId = (int) $PageId ? $PageId : 1; $this->DadosForm['nome_resid'] = filter_input(INPUT_GET, 'nome_resid', FILTER_DEFAULT); } print_r($this->DadosForm); print_r($this->PageId); $listarServicoContratado = new \App\gre\Models\GreListarServicoContratado(); $this->Dados['listUser'] = $listarServicoContratado->pesquisarServContr($this->PageId, $this->DadosForm); $carregarView = new \App\gre\core\ConfigView("gre/Views/Servico_Contratado/listarServicoContratado", $this->Dados); $carregarView->renderizarGre(); } }