Why do you need the switch inside the array? Can you try to remove the switch from the array and get the result of the switch statement before creating your array so that will will only look like this.
Appreciate the support, however that’s incorrect as well. $data is only valid when the expression is encased in quotes, it’s all around when that code gets evaluated. In your suggestion, $data is undefined at that point in time because it is still at the point where we are configuring CGridView. It needs to be encased in quotes so that as CGridView is running its internal methods, it evaluates $data at that point in time. This would work if I could somehow inject $arrayClass into the column (via a expressionData property, which does not exist).
I think we will just drop CGridView and use CListView as that allows for much more flexible rendering possibilities.