<?php
/*
+--------------------------------------------------------------------+
- | CiviCRM version 4.6 |
+ | CiviCRM version 4.7 |
+--------------------------------------------------------------------+
| Copyright CiviCRM LLC (c) 2004-2015 |
+--------------------------------------------------------------------+
*
* @package CRM
* @copyright CiviCRM LLC (c) 2004-2015
- * $Id$
- *
*/
/**
- * This class generates form components for processing a survey
- *
+ * This class generates form components for processing a survey.
*/
class CRM_Campaign_Form_Survey_Main extends CRM_Campaign_Form_Survey {
CRM_Utils_System::setTitle(ts('Configure Survey') . ' - ' . $this->_surveyTitle);
}
- $this->_cdType = CRM_Utils_Array::value('type', $_GET);
- $this->assign('cdType', FALSE);
- if ($this->_cdType) {
- $this->assign('cdType', TRUE);
- return CRM_Custom_Form_CustomData::preProcess($this);
- }
-
// when custom data is included in this page
if (!empty($_POST['hidden_custom'])) {
CRM_Custom_Form_CustomData::preProcess($this);
* array of default values
*/
public function setDefaultValues() {
- if ($this->_cdType) {
- return CRM_Custom_Form_CustomData::setDefaultValues($this);
- }
$defaults = $this->_values;
/**
* Build the form object.
- *
- * @return void
*/
public function buildQuickForm() {
- if ($this->_cdType) {
- return CRM_Custom_Form_CustomData::buildQuickForm($this);
- }
$this->add('text', 'title', ts('Title'), CRM_Core_DAO::getAttribute('CRM_Campaign_DAO_Survey', 'title'), TRUE);
/**
* Process the form.
- *
- * @return void
*/
public function postProcess() {
// store the submitted values in an array