Changeset 7440


Ignore:
Timestamp:
10/18/12 14:44:26 (7 years ago)
Author:
rafaelgobara
Message:

Ticket #3168 - Parametrizado o método para retornar ou não o nome acentuado

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/workflow/inc/local/classes/class.wf_location.php

    r5307 r7440  
    177177         * @access public 
    178178         */ 
    179         function getCitiesByKey($key, $state_id = 0, $include_districts = true) 
     179        function getCitiesByKey($key, $state_id = 0, $include_districts = true, $hasAccent = true) 
    180180        { 
    181181                if (!is_string($key) || !is_numeric($state_id) || !is_bool($include_districts)) 
     
    191191                } 
    192192 
     193                $city_name = 'c.city_name AS city_name,'; 
     194 
     195                if(!$hasAccent) 
     196                { 
     197                        $city_name = 'TO_ASCII(c.city_name) AS city_name,'; 
     198                } 
     199 
    193200                $sql = 
    194201                "SELECT 
    195202                        c.id_city AS id_city, 
    196                         c.city_name AS city_name, 
     203                        $city_name 
    197204                        s.id_state AS id_state, 
    198205                        s.state_name AS state_name, 
Note: See TracChangeset for help on using the changeset viewer.