Esempio n. 1
0
 public function behaviors()
 {
     $bs = array('AdminBehavior' => array('class' => 'application.admin.components.behaviours.AdminBehavior', 'fields' => array(array('name' => 'Город', 'attribute' => 'name', 'type' => 'text'), array('name' => 'Регион', 'attribute' => 'regionId', 'type' => 'autocomplete', 'source' => Yii::app()->createUrl('site/region'), 'valueField' => 'regionId', 'textField' => 'name', 'value' => $this->region->name), array('name' => 'Страна', 'attribute' => 'countryId', 'type' => 'dropdown', 'data' => array('model' => Country::model()->findAll(), 'valueField' => 'countryId', 'textField' => 'name'))), 'columns' => array('cityId', 'name')));
     return CMap::mergeArray(parent::behaviors(), $bs);
 }
Esempio n. 2
0
 public function behaviors()
 {
     $behaviors = CMap::mergeArray(parent::behaviors(), array('sortable' => array('class' => 'ext.sortable.SortableBehavior')));
     return $behaviors;
 }
Esempio n. 3
0
 public function behaviors()
 {
     $bs = array('AdminBehavior' => array('class' => 'application.admin.components.behaviours.AdminBehavior', 'fields' => array(array('name' => 'Регион', 'attribute' => 'name', 'type' => 'text'), array('name' => 'Страна', 'attribute' => 'countryId', 'type' => 'dropdown', 'data' => array('model' => Country::model()->findAll(), 'valueField' => 'countryId', 'textField' => 'name'))), 'columns' => array('regionId', 'name')));
     return CMap::mergeArray(parent::behaviors(), $bs);
 }
Esempio n. 4
0
 public function behaviors()
 {
     $bs = array('AdminBehavior' => array('class' => 'application.admin.components.behaviours.AdminBehavior', 'fields' => array(array('name' => 'Валюта', 'attribute' => 'name', 'type' => 'text')), 'columns' => array('currencyId', 'name')));
     return CMap::mergeArray(parent::behaviors(), $bs);
 }
Esempio n. 5
0
 /**
  *
  * @var type
  */
 public function behaviors()
 {
     $behaviors = array();
     $behaviors['UserBehavior'] = array('class' => 'application.modules.users.components.behaviors.UserBehavior');
     return array_merge(parent::behaviors(), $behaviors);
 }
Esempio n. 6
0
 public function behaviors()
 {
     return CMap::mergeArray(parent::behaviors(), array('Tag' => array('class' => 'application.components.activeRecordBehaviors.TagBehavior'), 'FileManager' => array('class' => 'application.components.activeRecordBehaviors.FileManagerBehavior', 'tags' => array('gallery' => array('title' => 'Галерея', 'data_type' => 'image'))), 'SportRel' => array('class' => 'application.modules.content.components.activeRecordBehaviors.SportRelBehavior')));
 }
Esempio n. 7
0
 public function behaviors()
 {
     $bs = array('AdminBehavior' => array('class' => 'application.admin.components.behaviours.AdminBehavior', 'fields' => array(array('name' => 'Email', 'attribute' => 'email', 'type' => 'text'), array('name' => 'Логин', 'attribute' => 'login', 'type' => 'text'), array('name' => 'Пароль', 'attribute' => 'password', 'type' => 'password'), array('name' => 'Имя', 'attribute' => 'name', 'type' => 'text'), array('name' => 'Фамилия', 'attribute' => 'lastName', 'type' => 'text'), array('name' => 'Телефон', 'attribute' => 'phone', 'type' => 'text')), 'columns' => array('adminUserId', 'name', 'lastName', 'email', 'phone')));
     return CMap::mergeArray(parent::behaviors(), $bs);
 }
Esempio n. 8
0
 public function behaviors()
 {
     return CMap::mergeArray(parent::behaviors(), array('tree' => array('class' => 'application.components.activeRecordBehaviors.NestedSetBehavior', 'leftAttribute' => self::LFT, 'rightAttribute' => self::RGT, 'levelAttribute' => self::DEPTH)));
 }
Esempio n. 9
0
 public function behaviors()
 {
     $bs = array('AdminBehavior' => array('class' => 'application.admin.components.behaviours.AdminBehavior', 'fields' => array(array('name' => 'Название', 'attribute' => 'title', 'type' => 'text'), array('name' => 'Контент', 'attribute' => 'text', 'type' => 'textEditor')), 'columns' => array('pageId', 'title')));
     return CMap::mergeArray(parent::behaviors(), $bs);
 }
Esempio n. 10
0
 public function behaviors()
 {
     $bs = array('AdminBehavior' => array('class' => 'application.admin.components.behaviours.AdminBehavior', 'fields' => array(array('name' => 'Вопрос', 'attribute' => 'question', 'type' => 'textarea'), array('name' => 'Ответ', 'attribute' => 'answer', 'type' => 'textEditor')), 'columns' => array('faqId', 'question')));
     return CMap::mergeArray(parent::behaviors(), $bs);
 }
Esempio n. 11
0
 public function behaviors()
 {
     return CMap::mergeArray(parent::behaviors(), array());
 }
Esempio n. 12
0
 public function behaviors()
 {
     return CMap::mergeArray(parent::behaviors(), ['FileManager' => ['class' => 'application.components.activeRecordBehaviors.FileManagerBehavior', 'tags' => ['files' => ['title' => 'Файлы', 'data_type' => 'image']]]]);
 }
Esempio n. 13
0
 public function behaviors()
 {
     $behaviors = parent::behaviors();
     $behaviors['nestedSetBehavior'] = array('class' => 'application.components.activeRecordBehaviors.NestedSetBehavior', 'hasManyRoots' => true, 'leftAttribute' => 'left', 'rightAttribute' => 'right', 'levelAttribute' => 'level');
     return $behaviors;
 }
Esempio n. 14
0
 public function behaviors()
 {
     return CMap::mergeArray(parent::behaviors(), ['NestedSet' => ['class' => 'application.components.activeRecordBehaviors.NestedSetBehavior', 'leftAttribute' => 'left', 'rightAttribute' => 'right', 'levelAttribute' => 'level', 'hasManyRoots' => true]]);
 }