Atualizando FilesValidade.class.php
This commit is contained in:
parent
4f70defd31
commit
d505c8f449
2 changed files with 6 additions and 6 deletions
8
vendor/action/users/users_save.php
vendored
8
vendor/action/users/users_save.php
vendored
|
|
@ -17,7 +17,7 @@ try{
|
|||
|
||||
/** Parametros de entrada */
|
||||
$userId = isset($_POST['user_id']) ? (int)filter_input(INPUT_POST, 'user_id', FILTER_SANITIZE_NUMBER_INT) : 0 ;
|
||||
$clientsId = isset($_POST['clients_id']) ? (int)filter_input(INPUT_POST, 'clients_id', FILTER_SANITIZE_NUMBER_INT) : 0;
|
||||
$companyId = isset($_POST['company_id']) ? (int)filter_input(INPUT_POST, 'company_id', FILTER_SANITIZE_NUMBER_INT) : 0;
|
||||
$companyId = isset($_POST['company_id']) ? (int)filter_input(INPUT_POST, 'company_id', FILTER_SANITIZE_SPECIAL_CHARS) : 0;
|
||||
$nameFirst = isset($_POST['name_first']) ? (string)filter_input(INPUT_POST, 'name_first', FILTER_SANITIZE_SPECIAL_CHARS) : '';
|
||||
$nameLast = isset($_POST['name_last']) ? (string)filter_input(INPUT_POST, 'name_last', FILTER_SANITIZE_SPECIAL_CHARS) : '';
|
||||
|
|
@ -32,7 +32,7 @@ try{
|
|||
|
||||
/** Validando os campos de entrada */
|
||||
$UsersValidate->setUserId($userId);
|
||||
$UsersValidate->setClientsId($clientsId);
|
||||
$UsersValidate->setcompanyId($companyId);
|
||||
$UsersValidate->setCompanyId($companyId);
|
||||
$UsersValidate->setNameFirst($nameFirst);
|
||||
$UsersValidate->setNameLast($nameLast);
|
||||
|
|
@ -60,7 +60,7 @@ try{
|
|||
} else {
|
||||
|
||||
/** Verifica se o usuário já se encontra cadastrado */
|
||||
if($Users->CheckEmail($UsersValidate->getUserId(), $UsersValidate->getClientsId(), $UsersValidate->getEmail()) > 0){
|
||||
if($Users->CheckEmail($UsersValidate->getUserId(), $UsersValidate->getcompanyId(), $UsersValidate->getEmail()) > 0){
|
||||
|
||||
/** Informo */
|
||||
throw new InvalidArgumentException('O e-mail informado já está sendo utilizado', 0);
|
||||
|
|
@ -68,7 +68,7 @@ try{
|
|||
|
||||
|
||||
/** Efetua um novo cadastro ou salva os novos dados */
|
||||
if ($Users->Save($UsersValidate->getUserId(), $UsersValidate->getClientsId(), $UsersValidate->getCompanyId(), $UsersValidate->getNameFirst(), $UsersValidate->getNameLast(), $UsersValidate->getEmail(), $UsersValidate->getBirthDate(), $UsersValidate->getGenre(), $UsersValidate->getActive(), $UsersValidate->getAdministrator(), $UsersValidate->getPassword(), $UsersValidate->getPasswordTemp(), $UsersValidate->getPasswordTempConfirm())){
|
||||
if ($Users->Save($UsersValidate->getUserId(), $UsersValidate->getcompanyId(), $UsersValidate->getCompanyId(), $UsersValidate->getNameFirst(), $UsersValidate->getNameLast(), $UsersValidate->getEmail(), $UsersValidate->getBirthDate(), $UsersValidate->getGenre(), $UsersValidate->getActive(), $UsersValidate->getAdministrator(), $UsersValidate->getPassword(), $UsersValidate->getPasswordTemp(), $UsersValidate->getPasswordTempConfirm())){
|
||||
|
||||
|
||||
/** Verifica se é para enviar e-mail de acesso ao usuário */
|
||||
|
|
|
|||
|
|
@ -41,7 +41,7 @@ class UsersValidate
|
|||
|
||||
}
|
||||
|
||||
public function setUsersId(int $usersId): void
|
||||
public function setUserId(int $usersId): void
|
||||
{
|
||||
|
||||
/** Tratamento da informação */
|
||||
|
|
@ -308,7 +308,7 @@ class UsersValidate
|
|||
|
||||
}
|
||||
|
||||
public function getUsersId() : ? int
|
||||
public function getUserId() : ? int
|
||||
{
|
||||
|
||||
return (int)$this->usersId;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue