Exemplo n.º 1
0
 * @package ProEthos-Admin
 * @subpackage user
 */
require "cab.php";
/* Admin Common */
$ok = ($perfil->valid('#ADM') or $perfil->valid('#SCR') or $perfil->valid('#COO'));
if ($ok == 0) {
    redirecina('main.php');
}
global $acao, $dd, $cp, $tabela;
require $include . 'sisdoc_colunas.php';
require $include . '_class_form.php';
$form = new form();
require 'form_css.php';
$cl = new users();
$cp = $cl->cp_admin();
$tabela = $cl->tabela;
$http_edit = 'admin_user_ed.php';
$http_redirect = '';
/** Comandos de Edicao */
echo '<CENTER><h2>' . msg('users') . '</h2></CENTER>';
$tela = $form->editar($cp, $tabela);
/** Caso o registro seja validado */
if ($form->saved > 0) {
    $cl->updatex();
    redirecina('admin_user.php');
} else {
    echo $tela;
}
echo '</div>';
echo $hd->foot();
Exemplo n.º 2
0
 * @copyright © Pan American Health Organization, 2013. All rights reserved.
 * @access public
 * @version v.0.13.46
 * @package Proethos
 * @subpackage Protocol
 */
/* Add Styles */
$style_add = array('proethos_form.css');
$active_page = 'my';
require "cab.php";
require $include . 'sisdoc_data.php';
require $include . '_class_form.php';
$form = new form();
require "form_css.php";
$uss = new users();
$cp = $uss->cp_myaccount();
$dd[0] = $ss->user_id;
$uss->id = $dd[0];
$tabela = 'usuario';
echo '<h1>' . msg('my_account') . '</h1>';
echo '<fieldset><legend>' . msg('my_account') . '</legend>';
$tela = $form->editar($cp, $uss->tabela);
if ($form->saved > 0) {
    $uss->updatex();
    redirecina('main.php');
} else {
    echo $tela;
    echo '<center>' . msg('my_profile') . '</center>';
    echo $perfil->display();
}
echo $hd->foot();
Exemplo n.º 3
0
// ProEthos under the terms of the ProEthos License as published by PAHO, which
// restricts commercial use of the Software.
//
// ProEthos is distributed in the hope that it will be useful, but WITHOUT ANY
// WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
// PARTICULAR PURPOSE. See the ProEthos License for more details.
//
// You should have received a copy of the ProEthos License along with the ProEthos
// Software. If not, see
// https://raw.githubusercontent.com/bireme/proethos/master/LICENSE.txt
$include = '';
$nosec = 1;
require "cab.php";
$nw = new users();
$chk = checkpost($dd[1]);
$nw->updatex();
echo '<H1>' . msg('user_new') . '</h1>';
$ok1 = ($perfil->valid('#ADM') or $perfil->valid('#MAS') or $perfil->valid('##MEM'));
$ok2 = ($perfil->valid('#ADC') and $dd[1] == 'Z');
/* Nao alterar - dados comuns */
if ($chk == $dd[90]) {
    echo '<h2>' . msg('chk_email_ok_tit') . '</h2>';
    echo '<table width="100%"><TR><TD>' . msg('chk_email_ok') . '</table>';
    $sql = "update " . $nw->tabela . " set us_ativo = 1, us_confirmed = 1 ";
    $sql .= " where us_email = '" . trim($dd[1]) . "' ";
    $rlt = db_query($sql);
} else {
    echo '<h2>' . msg('chk_email_erro_tit') . '</h2>';
    echo '<font color="red">';
    echo msg('chk_email_erro');
    echo '</font>';