Atualizando Produtos company
This commit is contained in:
parent
566094fef5
commit
d777313553
1 changed files with 9 additions and 9 deletions
18
vendor/view/users/users_datagrid.php
vendored
18
vendor/view/users/users_datagrid.php
vendored
|
|
@ -3,26 +3,26 @@
|
|||
/** Importação de classes */
|
||||
use vendor\model\Users;
|
||||
use vendor\model\Company;
|
||||
use vendor\model\Clients;
|
||||
use vendor\model\Companies;
|
||||
use vendor\controller\company\CompanyValidate;
|
||||
use vendor\controller\clients\ClientsValidate;
|
||||
use vendor\controller\Companies\CompaniesValidate;
|
||||
|
||||
/** Verifica se o token de acesso é válido */
|
||||
if($Main->verifyToken()){
|
||||
|
||||
/** Instânciamento de classes */
|
||||
$Users = new Users();
|
||||
$Clients = new Clients();
|
||||
$Companies = new Companies();
|
||||
$Company = new Company();
|
||||
$CompanyValidate = new CompanyValidate;
|
||||
$ClientsValidate = new ClientsValidate;
|
||||
$CompaniesValidate = new CompaniesValidate;
|
||||
|
||||
/** Carrega as configurações de paginação */
|
||||
$config = $Main->LoadConfigPublic();
|
||||
|
||||
/** Parametros de entrada */
|
||||
$companyId = isset($_POST['company_id']) ? (int)filter_input(INPUT_POST, 'company_id', FILTER_SANITIZE_NUMBER_INT) : $_SESSION['USERSCOMPANYID'];
|
||||
$clientsId = isset($_POST['clients_id']) ? (int)filter_input(INPUT_POST, 'clients_id', FILTER_SANITIZE_NUMBER_INT) : 0;
|
||||
$companiesId = isset($_POST['company_id']) ? (int)filter_input(INPUT_POST, 'company_id', FILTER_SANITIZE_NUMBER_INT) : 0;
|
||||
|
||||
/** Parâmetros de paginação **/
|
||||
$start = isset($_POST['start']) ? (int)filter_input(INPUT_POST,'start', FILTER_SANITIZE_NUMBER_INT) : 0;
|
||||
|
|
@ -31,7 +31,7 @@ if($Main->verifyToken()){
|
|||
|
||||
/** Valida o campo */
|
||||
$CompanyValidate->setCompanyId($companyId);
|
||||
$ClientsValidate->setClientsId($clientsId);
|
||||
$ClientsValidate->setClientsId($companiesId);
|
||||
|
||||
/** Consulta a quantidade de registros */
|
||||
$NumberRecords = $Users->Count($CompanyValidate->getCompanyId(), $ClientsValidate->getClientsId())->qtde;
|
||||
|
|
@ -76,7 +76,7 @@ if($Main->verifyToken()){
|
|||
|
||||
<div class="col-md-4 text-right">
|
||||
|
||||
<button type="button" class="btn btn-success btn-sm" onclick="request('FOLDER=view&TABLE=users&ACTION=users_form&company_id=<?php echo $CompanyValidate->getCompanyId();?>&clients_id=<?php echo $ClientsValidate->getClientsId();?>', '#loadContent', true, '', '', '', 'Preparando formulário', 'blue', 'circle', 'sm', true)" data-toggle="tooltip" data-placement="left" title="Cadastrar novo usuário">
|
||||
<button type="button" class="btn btn-success btn-sm" onclick="request('FOLDER=view&TABLE=users&ACTION=users_form&company_id=<?php echo $CompanyValidate->getCompanyId();?>&company_id=<?php echo $ClientsValidate->getClientsId();?>', '#loadContent', true, '', '', '', 'Preparando formulário', 'blue', 'circle', 'sm', true)" data-toggle="tooltip" data-placement="left" title="Cadastrar novo usuário">
|
||||
|
||||
<i class="fas fa-plus-circle mr-1"></i>Novo
|
||||
|
||||
|
|
@ -143,7 +143,7 @@ if($Main->verifyToken()){
|
|||
<td><?php echo $result->email; ?></td>
|
||||
<td class="text-center" width="30"><?php echo date("d/m/Y",strtotime($result->date_register)); ?></td>
|
||||
<td class="text-center" width="40"><?php echo $result->active == "S" ? "Sim" : "Não"; ?></td>
|
||||
<td class="text-center" width="20"><a type="button" class="btn btn-light btn-sm" onclick="request('FOLDER=view&TABLE=users&ACTION=users_form&users_id=<?php echo $result->users_id; ?>&company_id=<?php echo $CompanyValidate->getCompanyId(); ?>&clients_id=<?php echo $ClientsValidate->getClientsId(); ?>', '#loadContent', true, '', '', '', 'Preparando formulário', 'blue', 'circle', 'sm', true)"><i class="far fa-edit mr-1"></i></a></td>
|
||||
<td class="text-center" width="20"><a type="button" class="btn btn-light btn-sm" onclick="request('FOLDER=view&TABLE=users&ACTION=users_form&users_id=<?php echo $result->users_id; ?>&company_id=<?php echo $CompanyValidate->getCompanyId(); ?>&company_id=<?php echo $ClientsValidate->getClientsId(); ?>', '#loadContent', true, '', '', '', 'Preparando formulário', 'blue', 'circle', 'sm', true)"><i class="far fa-edit mr-1"></i></a></td>
|
||||
|
||||
</tr>
|
||||
|
||||
|
|
@ -192,7 +192,7 @@ if($Main->verifyToken()){
|
|||
|
||||
<div class="col-md-4 text-right">
|
||||
|
||||
<button type="button" class="btn btn-success btn-sm" onclick="request('FOLDER=view&TABLE=users&ACTION=users_form&company_id=<?php echo $CompanyValidate->getCompanyId();?>&clients_id=<?php echo $ClientsValidate->getClientsId();?>', '#loadContent', true, '', '', '', 'Preparando formulário', 'blue', 'circle', 'sm', true)">
|
||||
<button type="button" class="btn btn-success btn-sm" onclick="request('FOLDER=view&TABLE=users&ACTION=users_form&company_id=<?php echo $CompanyValidate->getCompanyId();?>&company_id=<?php echo $ClientsValidate->getClientsId();?>', '#loadContent', true, '', '', '', 'Preparando formulário', 'blue', 'circle', 'sm', true)">
|
||||
|
||||
<i class="fas fa-plus-circle mr-1"></i>Cadastrar novo usuário
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue