Cgridview Search Problem

Hello. I’m using CGridView to list all products for site, when I use (basic)search filters Yii dont fill all fields in CGrid, first I was think that is template, but when I remove my template and put Yii defaults I get same problem.

Model and Controller is made with Gii so search() function is default, rules for search are also default.

Search working good just ajax Yii dont fill all fields, I was try also without ajax and I had same problem.

Here is screenshot to be more clear. Any suggestions?

Are those fields all in the same model? Can you post your model rules, any default scope and the search method?

Collection name is only realation, but when I more that relation I have some situation. All other fields are in same model.




        public function rules()

        {

            return array(

                array('cid, name, code, colors, description, keywords, cat_id', 'required'),

                array('cid, code, size, cat_id', 'length', 'max' => 255),

                array('pid, cid, name, description, code, size, colors', 'safe', 'on' => 'search'),

            );

        }



Search function is made by Gii, so its defult.

I suggest that you check my RelatedBehaviorExtension and the demo of the extension.