*
* @package CRM
* @copyright CiviCRM LLC (c) 2004-2015
- * $Id$
- *
*/
/**
- * Business object for managing custom data groups
- *
+ * Business object for managing custom data groups.
*/
class CRM_Core_BAO_CustomGroup extends CRM_Core_DAO_CustomGroup {
if ((!empty($params['is_multiple']) || $isMultiple) &&
($params['is_multiple'] != $isMultiple)
) {
- $oldTableName = CRM_Core_DAO::getFieldValue('CRM_Core_DAO_CustomGroup',
+ $oldTableName = CRM_Core_DAO::getFieldValue(
+ 'CRM_Core_DAO_CustomGroup',
$params['id'],
'table_name'
);
* (reference) the group tree being build.
* @param string $table
* Table name.
- * @param unknown_type $groupID
+ * @param int $groupID
* Custom group ID.
- * @param unknown_type $fieldID
+ * @param int $fieldID
* Custom field ID.
*/
static public function buildCustomFieldData($dao, &$groupTree, $table, $groupID, $fieldID) {
*
* @return string
* title
- *
*/
public static function getTitle($id) {
return CRM_Core_DAO::getFieldValue('CRM_Core_DAO_CustomGroup', $id, 'title');
*
* @return array
* array consisting of all group and field details
- *
- *
*/
public static function &getGroupDetail($groupId = NULL, $searchable = NULL, &$extends = NULL, $inSelector = NULL) {
// create a new tree
*
* @param int $entityID
* @param bool $allSubtypes
- *
- * @return void
- *
*/
private static function _addWhereAdd(&$customGroupDAO, $entityType, $entityID = NULL, $allSubtypes = FALSE) {
$addSubtypeClause = FALSE;
/**
* Delete the Custom Group.
*
- * @param $group
- * Object the DAO custom group object.
+ * @param CRM_Core_BAO_CustomGroup $group
+ * Custom group object.
* @param bool $force
* whether to force the deletion, even if there are custom fields.
*
* @return bool
- * false if field exists for this group, true if group gets deleted.
+ * False if field exists for this group, true if group gets deleted.
*/
public static function deleteGroup($group, $force = FALSE) {
- //check wheter this contain any custom fields
+ //check whether this contain any custom fields
$customField = new CRM_Core_DAO_CustomField();
$customField->custom_group_id = $group->id;
$customField->find();
}
/**
- * @param $groupTree
- * @param $defaults
+ * Set defaults.
+ *
+ * @param array $groupTree
+ * @param array $defaults
* @param bool $viewMode
* @param bool $inactiveNeeded
* @param int $action
}
/**
- * @param $groupTree
+ * PostProcess function.
+ *
+ * @param array $groupTree
* @param array $params
* @param bool $skipFile
*/
* Return inactive custom groups.
* @param string $prefix
* Prefix for custom grouptree assigned to template.
- *
- * @return void
*/
public static function buildQuickForm(&$form, &$groupTree, $inactiveNeeded = FALSE, $prefix = '') {
$form->assign_by_ref("{$prefix}groupTree", $groupTree);
}
/**
- * Extract the get params from the url, validate
- * and store it in session
+ * Extract the get params from the url, validate and store it in session.
*
* @param CRM_Core_Form $form
* The form object.