Tbextendedgridview And Sortablerows


I use YiiBosster TbExtendedGridView in my code and want implement sortableRows feature

I write these codes

$this->widget('bootstrap.widgets.TbExtendedGridView', array(  

    'sortableRows' => true,

    'sortableAttribute' => 'position',

    'sortableAjaxSave' => true,

    'sortableAction' => 'xadmin/xgallery/gallery/imageSortable',

    'afterSortableUpdate' => 'js:function(){}',


    'dataProvider' => $images,




public function actions() {

    return array(

        'imageSortable' => array(

        'class' => 'bootstrap.actions.TbSortableAction',

        'modelName' => 'GalleryImage'



but it dont works and I check $_POST[‘sortOrder’] and understant that $_POST[‘sortOrder’] is equal to original sorting order (Before sorting)

where is problem ?

:blink: Any reply?

Let me know if you find some solution please.

yii 1.1.14什么时候发布呀


I had the same problem. The fix was that the value for sort_order must not be Zero and the Interger for the sort_order has to be unique. So if you have 2 columns with sort_order 1 it wont work.