yiisoft/yii — pull request #722 by resurtm (2012-05-17 14:42:49+00:00)
Title: CHtml::listData(): Ability to accept PHP expression as value, text and group

API BC is okay.

Why we need this? We can use multiple model fields and construct any strings without adding additional virtual attributes to the model.

Examples of using. Arbitary old way:
```php
findAll(), 'id', 'title')
); ?>

findAll(), 'id', 'title', 'category.title')
); ?>
```

Result:

![old](http://storage5.static.itmages.ru/i/12/0517/h_1337265547_2244121_d4beca1b2b.png)

New way:
```php
findAll(),
'id',
array('$data->title.", ".$data->category->title')
)
); ?>

findAll(),
'id',
array('$data->title.", ".$data->category->title'),
array('$data->id.", ".$data->title')
)
); ?>
```

Result:

![new](http://storage6.static.itmages.ru/i/12/0517/h_1337265551_9531888_77dd0db7ee.png)