2016
01-13
01-13
CGridView查询中 unsetAttributes() 方法详解
控制器代码:publicfunctionactionIndex(){$model=newStaff('search');if(isset($_GET['Manager']))$model->attributes=$_GET['Manager'];$this->render('index',array('model'=>$model,));}将model传到CGridView,数据库有一条记录,但是却不显示。CGridView代码部分如下:<?php$this->widget('zii.widgets.grid.CGridView',array('ajaxUpdate'=>false,'id'=>'staff-grid','itemsCssClass'=>'data_list'...
继续阅读 >