?> <div class="group-1"> <?php // echo ProPropertyType::getDropDownSelectGroup('Listing[property_type_1]', 'Listing_property_type_1', $model->property_type_1, 'Select'); ?> <div class="w-170 f-left"> <?php // thực tế đang lưu cái property_type_1 để search và phục vụ cho transaction echo $form->dropDownlist($model, 'property_type_2', ProPropertyType::getListOptionParent(), array('class' => 'text ad_nb_property_first', 'empty' => 'Select')); ?> </div> <div class="w-220 f-left l_padding_20"> <?php $arrType1 = array(); if ($model->property_type_2) { echo ProPropertyType::getOptionSelectGroupByParent($model->property_type_2, "Listing[property_type_1]", "ad_nb_replace_{$model->property_type_1}", $model->property_type_1, "Select", "ad_nb_property_second ad_nb_replace_{$model->property_type_1}"); } else { echo $form->dropDownlist($model, 'property_type_1', $arrType1, array('class' => 'text ad_nb_property_second', 'empty' => 'Select')); } ?> </div> <div class="clear" style='clear: both;'></div> <?php echo $form->error($model, 'property_type_1'); ?> </div> </div> <div class="unit_from in-row clearfix ad_nb_show_all <?php echo implode(' ', ProPropertyType::$A_FIELD_MAP['unit_from']);
<div class="display_none"> <?php $sr_parent = ProPropertyType::getListOptionParent(array('normal_select' => 1)); foreach ($sr_parent as $parent_id => $parent_name) { ?> <?php echo ProPropertyType::getOptionSelectGroupByParent($parent_id, "ad_nb_replace_{$parent_id}", "ad_nb_replace_{$parent_id}", "", "Select", "ad_nb_replace_{$parent_id}"); ?> <?php // echo CHtml::dropDownList('maximum_bedroom', '', 1, array('empty' => 'Select', 'class'=>"sr_replace$parent_id")); } ?> <!-- for dropdown list parent property type need add more attributes to option tag --> <?php $arrModelParentPro = ProPropertyType::getListOptionParent(array('model_only' => 1)); foreach ($arrModelParentPro as $item) { ?> <span class="group_show_parent_<?php echo $item->id; ?> "><?php echo $item->group_show; ?> </span> <?php } ?> <!-- for dropdown list parent property type need add more attributes to option tag --> </div>