$sortableItems = $option->getSortableItems();

$this->widget('zii.widgets.jui.CJuiSortable',
              array(
                    'id'=>'order',
                    'items'=>$sortableItems,
                    'itemTemplate'=>'<li id="{id}" class="ui-state-default"><span class="ui-icon ui-icon-arrowthick-2-n-s"></span>{content}</li>',                                
));

The widget runs and looks fine in the page. However, when I go drag and drop, many <li class="ui-state-default ui-sortable-placeholder" style="visibility: hidden;"/> are created between two elements and the items don't change their positions.

Does someone know what is happening?

有帮助吗?

解决方案

Due to the error oddity, it seems that you are having a jqueryUI library conflict. Try to see on your view how many scripts are loading and perhaps the issue may be gone.

:)

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top