D7net
Home
Console
Upload
information
Create File
Create Folder
About
Tools
:
/
var
/
www
/
html
/
chatweb02
/
application
/
views
/
admin
/
Filename :
usuarios.php
back
Copy
<table class="tabela2" style="margin-top:10px"> <thead > <tr> <th style="height:40px">Codigo</th> <th style="height:40px">Nome</th> <th style="height:40px">Usuário</th> <th style="height:40px">Perfil</th> <th style="height:40px">Ações</th> <th style="height:40px"></th> </tr> </thead> <tbody> <?php foreach ($usuarios as $usuario) { ?> <tr> <td style="height:60px"><?php echo $usuario->cht_usu_id; ?></td> <td style="height:60px"><?php echo $usuario->cht_usu_nome; ?></td> <td style="height:60px"><?php echo $usuario->cht_usu_login; ?></td> <td style="height:60px"><?php echo $usuario->cht_usu_perfil =='A' ? 'Administrador' : 'Chat'; ?></td> <td style="height:60px"> <button type="button" class="btn btn-primary" onclick="javascript:usuario(<?php echo $usuario->cht_usu_id; ?>)">Editar</button> </td> <td style="height:60px"> <div class="custom-control custom-switch"> <input type="checkbox" class="custom-control-input" id="ck-status-<?php echo $usuario->cht_usu_id; ?>" onchange="javascript:statususuario(<?php echo $usuario->cht_usu_id; ?>,this.checked);" <?php echo $usuario->cht_usu_status=='A'? 'checked="checked"' : ''; ?> > <label class="custom-control-label" for="ck-status-<?php echo $usuario->cht_usu_id; ?>" id="lb-status-<?php echo $usuario->cht_usu_id; ?>"><?php echo $usuario->cht_usu_status=='A'? 'Ativo' : 'Inativo'; ?></label> </div> </td> </tr> <?php } ?> </tbody> </table> <nav aria-label="Page navigation example"> <ul class="pagination"> <li class="page-item"> <a class="page-link" href="javascript:void(0)" aria-label="Previous" onclick="javascript:usuarios(1)"> <span aria-hidden="true">«</span> </a> </li> <?php for($pag=0;$pag<=($paginas/5)-1;$pag++){ ?> <li class="page-item <?php echo $pagina==($pag+1) ? 'active' : ''; ?>"><a class="page-link " href="javascript:void(0)" onclick="javascript:usuarios(<?php echo $pag+1; ?>)" ><?php echo $pag+1; ?></a></li> <?php } ?> <li class="page-item"> <a class="page-link" href="javascript:void(0)" aria-label="Next" onclick="javascript:usuarios(<?php echo ($paginas/5); ?>)"> <span aria-hidden="true">»</span> </a> </li> </ul> </nav> <div class="form-group" style="margin-top:40px"> <button type="button" class="btn btn-success admin" onclick="javascript:usuarionovo()">Novo</button> <button type="button" class="btn btn-secondary admin">Voltar</button> </div>