I am a newbie in YII and building my first application using it. I am using CTabView in my application and it works fine. Here’s a snippet of code i am using:
<?php
$user_detail = User::model()->findByAttributes(array(‘id’=>Yii::app()->user->id)); // User data
But my issue is that tab system works fine if everything like writing logic, querying the database is done in the view itself, which is not good, for example for userpreferences i want to call controller action, write my logic there and render the view from there. But, i am unable to do this. If cTabView is for views specific tasks only, then do i need to write all the logic in the view itself?
I want to list user data in managepreferences view and want to update the data from controller istead of the view itself.