+--------------------------------------------------------------------+
| CiviCRM version 4.6 |
+--------------------------------------------------------------------+
- | Copyright CiviCRM LLC (c) 2004-2014 |
+ | Copyright CiviCRM LLC (c) 2004-2015 |
+--------------------------------------------------------------------+
| This file is a part of CiviCRM. |
| |
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
*
* @package CRM
- * @copyright CiviCRM LLC (c) 2004-2014
+ * @copyright CiviCRM LLC (c) 2004-2015
* $Id$
*
*/
protected $_id;
/**
- * The default values for form fields
+ * The default values for form fields.
*
* @var int
*/
protected $_values;
/**
- * The name of the BAO object for this form
+ * The name of the BAO object for this form.
*
* @var string
*/
protected $_BAOName;
/**
- * Basic setup
+ * Explicitly declare the form context.
+ */
+ public function getDefaultContext() {
+ return 'create';
+ }
+
+ /**
+ * Basic setup.
*/
public function preProcess() {
- $this->_id = $this->get('id');
+ $this->_id = $this->get('id');
$this->_BAOName = $this->get('BAOName');
- $this->_values = array();
+ $this->_values = array();
if (isset($this->_id)) {
$params = array('id' => $this->_id);
// this is needed if the form is outside the CRM name space
}
/**
- * Add standard buttons
+ * Add standard buttons.
*
* @return void
*/
);
}
}
+
}