clevertech/YiiBooster — pull request #955 by jayala (2014-09-24 02:01:18+00:00)
Title: Typeahead support for multiple and bloodhound

With this modifications you can declare multiple datasets and they can be Bloodhound datasets as well (by giving to the source array a 'name').
Examples of the datasets configuration:
```
'datasets' => array(
array(
'source' => array(
'name' => 'Ajax source',
'datumTokenizer' => "js:Bloodhound.tokenizers.obj.whitespace('value')",
'queryTokenizer' => "js:Bloodhound.tokenizers.whitespace",
'remote' => '/index.php?r=site/lookFor&term=%QUERY'
),
),
array(
'source' => array('Alabama', 'Alaska', 'Arizona', 'Arkansas', 'California',
'Colorado', 'Connecticut', 'Delaware', 'Florida', 'Georgia',
'Hawaii', 'Idaho', 'Illinois', 'Indiana', 'Iowa', 'Kansas',
'Kentucky', 'Louisiana', 'Maine', 'Maryland', 'Massachusetts',
'Michigan', 'Minnesota', 'Mississippi', 'Missouri', 'Montana',
'Nebraska', 'Nevada', 'New Hampshire', 'New Jersey',
'New Mexico', 'New York', 'North Dakota', 'North Carolina',
'Ohio', 'Oklahoma', 'Oregon', 'Pennsylvania', 'Rhode Island',
'South Carolina', 'South Dakota', 'Tennessee', 'Texas',
'Utah', 'Vermont', 'Virginia', 'Washington', 'West Virginia',
'Wisconsin', 'Wyoming'
),
)
),
```
or for one dataset:
```
'datasets' => array(
'source' => array(
'name' => 'Ajax source',
'datumTokenizer' => "js:Bloodhound.tokenizers.obj.whitespace('value')",
'queryTokenizer' => "js:Bloodhound.tokenizers.whitespace",
'remote' => '/index.php?r=site/lookFor&term=%QUERY'
),
),
```