The Multiple Feature Not Working In Select2 Ext.

I’ve added the select2 search in advenced search from, it works yet not with ‘multiple’ htmlOptions.




$this->widget('bootstrap.widgets.TbGridView', 

    array(

	'id'=>'assortment-grid',

    // 'type'=>'striped bordered condensed',

    'itemsCssClass' => 'table-bordered items',

    'dataProvider'=>$model->search(),

    'filter' => $model,

    'template'=>"{items}\n{pager}",

	'htmlOptions'=>array('enctype' => 'multipart/form-data'),

    'columns'=>array(			

                array('name'=>'sku', 'header'=>'Артикул'),

                array('name'=>'agroup', 

						'header'=>'Марка', 

						'value' => '$data->Groupname',

						//'filter' => $groupFilter 

						),

				array('name'=>'subgroup', 

						'header'=>'Подгруппа', 

						//'value' => '$data->Groupname',

						//'filter' => $subgroupFilter

						),

                array('name'=>'title', 'header'=>'Наименование'),

                array('name'=>'measure_unit', 'header'=>'Ед. Измерения'),

...

                                ),

                        ),

                ),      

    ),

));



_search.php invoked thru ‘Advanced Search’ btn. where select2 is located:




<div class="wide form">


<?php $form=$this->beginWidget('CActiveForm', array(

	'action'=>Yii::app()->createUrl($this->route),

	'method'=>'get',

));	

echo '<table border="0" width="100%"><tr><td width="30%">';

			$GroupArray = CHtml::listData(AssortmentGroups::model()->findAll(), 'id', 'name');

				echo 'Auto make</br>';

				// Working with model SELECT2 

				  $this->widget('ext.select2.ESelect2',array(

				 'name' => 'Assortment[agroup]',

			          'model'=>$model,

				  'data'=>$GroupArray,

				  /* 'htmlOptions'=>array( 

						 'multiple'=>'multiple',

					   ),  */

				));  

				?>

		</td>

		<td valign="top" style='padding:0 0 0 15px'>

			<?php echo '  Subgroup</br>';

			$SubgroupArray = CHtml::listData(AssortmentSubgroups::model()->findAll(), 'name', 'name');

			$this->widget('ext.select2.ESelect2',array(

				 'name' => 'Assortment[subgroup]',

			     'model'=>$model,

				  'data'=>$SubgroupArray,

				  'htmlOptions'=>array( 

						 'multiple'=>'multiple',

					   ),  

				));

		</td>

		

		<td width="30%"></td>

	</tr>

</table>

<?php echo CHtml::submitButton('Выбрать', array('class' => 'btn btn-mini btn-info')); ?>

<?php $this->endWidget(); ?>

</div><!-- search-form -->



When i add


 'htmlOptions'=>array('multiple'=>'multiple', ),

as i’ve done in the second search field and press the ‘Search’ btn. the ‘500 error’ window pops up. See the attached file.

What’s wrong?

Hi,

try to use multple equal to true