2amigos/yiiwheels — pull request #43 by acorncom (2013-08-12 23:30:00+00:00)
Title: Changed JS position requested to be in the onDocumentReady() function

Select2 options don't take affect unless we're in the onReady() method.

@tonydspaniard I'm using a version I've hacked on a bit which is where I found the problem. We haven't yet upgraded to Yiistrap / YiiWheels, but I'm pretty sure this is a bug in the native version as well.

Yiistrap's Bootstrap (`TbApi`) component's default `$position` for is `CClientScript::POS_END`, not `CClientScript::POS_READY`.

https://github.com/Crisu83/yiistrap/blob/master/components/TbApi.php#L176
https://github.com/Crisu83/yiistrap/blob/master/components/TbApi.php#L190