public function __set($name, $value)
 {
     if ($name == 'regions') {
         $this->regionsCount = count((array) $value);
     }
     parent::__set($name, $value);
 }
 public function setAttributes($values, $safeOnly = true)
 {
     if (isset($values['questionsQueue']) && is_string($values['questionsQueue'])) {
         $values['questionsQueue'] = CJSON::decode($values['questionsQueue']);
     }
     if (isset($values['deletedQuestions']) && is_string($values['deletedQuestions'])) {
         $values['deletedQuestions'] = CJSON::decode($values['deletedQuestions']);
     }
     parent::setAttributes($values, $safeOnly);
 }
 public function attributeLabels()
 {
     return array('comment' => "Комментарий") + parent::attributeLabels();
 }
 public function setAttributes($values, $safeOnly = true)
 {
     $this->methodsOfCollectionData = array();
     return parent::setAttributes($values, $safeOnly);
 }
 public function rules()
 {
     return array_merge(array(array('fileSMS, fileEmail', 'file', 'types' => array('csv'), "allowEmpty" => true), array('fileWithClientData', 'file', "allowEmpty" => true), array('fileSMS', 'FileIsNecessaryValidator', 'needFileMethodName' => 'needSMSFile'), array('fileEmail', 'FileIsNecessaryValidator', 'needFileMethodName' => 'needEmailFile'), array('fileWithClientData', 'FileIsNecessaryValidator', 'needFileMethodName' => 'needFileWithClientData'), array('fileWithClientData, fileSMS, fileEmail', 'safe')), parent::rules());
 }
 public function attributeLabels()
 {
     return array('compareWithAnotherOrganizationsYesRussian' => 'Да, с российскими', 'compareWithAnotherOrganizationsYesEuropean' => 'Да, с европейскими', 'compareWithAnotherOrganizationsYesWorld' => 'Да, с мировыми', 'compareWithAnotherOrganizationsNo' => 'Не требуется', 'whoWillUseReportMarketing' => 'Отдел маркетинга и рекламы', 'whoWillUseReportCommercial' => 'Коммерческий отдел', 'whoWillUseReportTopManagement' => 'Топ-менеджмент', 'whoWillUseReportInvestors' => 'Собственники, учредители, инвесторы', 'reportTypeExcelSPSS' => 'Массив данных в Excel, SPSS (предоставляется бесплатно)', 'reportTypeAudio' => 'Аудиозаписи анкет в mp3 для телефонных опросов (предоставляются бесплатно)', 'reportTypeTableAndChartsExcel' => 'Таблицы и диаграммы по вопросам анкеты (Excel)', 'reportTypeMarketingInterpretation' => 'Маркетинговая интерпретация данных, выводы и рекомендации (Word/ PDF)', 'reportTypeSmallPresentation' => 'Краткая презентация до 20 слайдов с основными выводами (PowerPoint)', 'reportTypePersonalCabinet' => 'Отслеживание исполнения проекта онлайн в личном кабинете (предоставляется бесплатно)') + parent::attributeLabels();
 }
 public function setAttributes($values, $safeOnly = true)
 {
     $this->purposes = array();
     return parent::setAttributes($values, $safeOnly);
 }