Ignore:
Timestamp:
02/08/13 10:50:40 (11 years ago)
Author:
alexandrecorreia
Message:

Ticket #2507 - Retira os caracteres especiais dentro do nome e do campo descricao

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sandbox/webservice/api/rest/admin/CreateUserResource.php

    r7859 r7878  
    2727                                $loginUser              = trim($this->getParam('accountLogin')); 
    2828                                $emailUser              = trim($this->getParam('accountEmail')); 
    29                                 $nameUser               = trim($this->getParam('accountName')); 
     29                                $nameUser               = $common->convertChar(trim($this->getParam('accountName'))); 
    3030                                $profileUser    = trim($this->getParam('accountProfile')); 
    3131                                $passwordUser   = trim($this->getParam('accountPassword')); 
     
    3535                                $rgUser                 = trim($this->getParam('accountRg')); 
    3636                                $rgUF                   = trim($this->getParam('accountRgUf')); 
    37                                 $description    = trim($this->getParam('accountDescription')); 
     37                                $description    = $common->convertChar(trim($this->getParam('accountDescription'))); 
    3838 
    3939                                // Field Validation 
     
    8383 
    8484                                // Characters not permited login 
    85                                 $msg = $common->validateCharacters($loginUser); 
     85                                $msg = $common->validateCharacters( $loginUser, "accountLogin" ); 
    8686 
    8787                                if( $msg['status'] == false ) 
    8888                                { 
    89                                         Errors::runException( "ADMIN_FIELDS_VALIDATE", $msg['msg'] ); 
     89                                        Errors::runException( "ADMIN_FIELDS_VALIDATE", $msg['msg'] . " : accountLogin" ); 
     90                                } 
     91                                 
     92                                //Characters not permited name 
     93                                $msg = $common->validateCharacters($nameUser); 
     94 
     95                                if( $msg['status'] == false ) 
     96                                { 
     97                                        Errors::runException( "ADMIN_FIELDS_VALIDATE", $msg['msg'] . " : accountName" ); 
    9098                                } 
    9199 
Note: See TracChangeset for help on using the changeset viewer.