Fixed ordering for Autocomplete on countries and customers

This commit is contained in:
Karl Cordes 2010-03-11 10:41:05 +11:00
parent 53f2d3fccc
commit 75f8434a9b
2 changed files with 3 additions and 2 deletions

View file

@ -79,7 +79,7 @@ class CountriesController extends AppController {
$countries = $this->Country->find('all', array(
'conditions' => array(
'Country.name LIKE' => '%'.$query.'%'
),'fields' => array('Country.name')
),'fields' => array('Country.name'), 'order' =>array('Country.name ASC')

View file

@ -111,7 +111,8 @@ class CustomersController extends AppController {
$customers = $this->Customer->find('all', array(
'conditions' => array(
'Customer.name LIKE' => '%'.$query.'%'
),'fields' => array('Customer.name')
),'fields' => array('Customer.name'),
'order' => array('Customer.name ASC')