Commit 3d08bf52 authored by colemanw's avatar colemanw

Merge pull request #3063 from eileenmcnaughton/rebase

CRM-14581 upgrade Multisite form including stdise group api
parents 4e261b4d c85faa08
......@@ -77,9 +77,10 @@ class CRM_Activity_BAO_Activity extends CRM_Activity_DAO_Activity {
* of time. This is the inverse function of create. It also stores all the retrieved
* values in the default array
*
* @param array $params (reference ) an assoc array of name/value pairs
* @param array $defaults (reference ) an assoc array to hold the flattened values
* @param string $activityType activity type
* @param array $params (reference ) an assoc array of name/value pairs
* @param array $defaults (reference ) an assoc array to hold the flattened values
*
* @internal param string $activityType activity type
*
* @return object CRM_Core_BAO_Meeting object
* @access public
......@@ -271,14 +272,15 @@ class CRM_Activity_BAO_Activity extends CRM_Activity_DAO_Activity {
/**
* Function to process the activities
*
* @param object $form form object
* @param array $params associated array of the submitted values
* @param array $ids array of ids
* @param string $activityType activity Type
* @param boolean $record true if it is Record Activity
* @param array $params associated array of the submitted values
*
* @internal param object $form form object
* @internal param array $ids array of ids
* @internal param string $activityType activity Type
* @internal param bool $record true if it is Record Activity
* @access public
*
* @return
* @return $this|null|object
*/
public static function create(&$params) {
// check required params
......@@ -1753,10 +1755,13 @@ WHERE activity.id IN ($activityIds)";
/**
* Function to add activity for Membership/Event/Contribution
*
* @param object $activity (reference) particular component object
* @param string $activityType for Membership Signup or Renewal
* @param object $activity (reference) particular component object
* @param string $activityType for Membership Signup or Renewal
*
*
* @param null $targetContactID
*
* @return bool
* @static
* @access public
*/
......
......@@ -188,6 +188,9 @@ class CRM_Admin_Form_Preferences extends CRM_Core_Form {
array('&nbsp;&nbsp;', '&nbsp;&nbsp;', '<br/>')
);
break;
case 'entity_reference':
$this->addEntityRef($fieldName, $fieldValue['title'], CRM_Utils_Array::value('options', $fieldValue, array()));
}
}
......@@ -264,6 +267,7 @@ class CRM_Admin_Form_Preferences extends CRM_Core_Form {
case 'text':
case 'select':
case 'radio':
case 'entity_reference':
$this->_config->$settingName = CRM_Utils_Array::value($settingName, $this->_params);
break;
......
......@@ -48,26 +48,31 @@ class CRM_Admin_Form_Preferences_Multisite extends CRM_Admin_Form_Preferences {
'html_type' => 'checkbox',
'title' => ts('Enable Multi Site Configuration'),
'weight' => 1,
'description' => ts('Multi Site provides support for sharing a single CiviCRM database among multiple sites.') . ' ' . $msDoc,
'description' => ts('Make CiviCRM aware of multiple domains. You should configure a domain group if enabled') . ' ' . $msDoc,
),
'uniq_email_per_site' => array(
/** Remove this checkbox until some one knows what this setting does
'uniq_email_per_site' => array(
'html_type' => 'checkbox',
'title' => ts('Ensure multi sites have a unique email per site'),
'weight' => 2,
'description' => NULL,
),
*/
'domain_group_id' => array(
'html_type' => 'text',
'title' => ts('Parent group for this domain'),
'html_type' => 'entity_reference',
'title' => ts('Domain Group'),
'weight' => 3,
'description' => ts('Enter the group ID (civicrm_group.id).'),
'options' => array('entity' => 'group', 'select' => array('minimumInputLength' => 0)),
'description' => ts('Contacts created on this site are added to this group'),
),
/** Remove this checkbox until some one knows what this setting does
'event_price_set_domain_id' => array(
'html_type' => 'text',
'title' => ts('Domain for event price sets'),
'weight' => 4,
'description' => NULL,
),
*/
),
);
......
......@@ -1112,8 +1112,8 @@ LEFT JOIN civicrm_country ON (civicrm_address.country_id = civicrm_country.id)
}
$values[$rid]['action'] = CRM_Core_Action::formLink(
$links,
$mask,
$links,
$mask,
$replace,
ts('more'),
FALSE,
......
......@@ -194,7 +194,6 @@ function _civicrm_api3_case_delete_spec(&$params) {
*/
function civicrm_api3_case_get($params) {
$options = _civicrm_api3_get_options_from_params($params);
//search by client
if (!empty($params['contact_id'])) {
$ids = array();
......
......@@ -657,6 +657,7 @@ function _civicrm_api3_apply_filters_to_dao($filterField, $filterValue, &$dao) {
* @param string $entity
* @param string $action
*
* @throws API_Exception
* @return array $options options extracted from params
*/
function _civicrm_api3_get_options_from_params(&$params, $queryObject = FALSE, $entity = '', $action = '') {
......@@ -1030,9 +1031,12 @@ function _civicrm_api3_basic_get($bao_name, &$params, $returnAsSuccess = TRUE, $
/**
* Function to do a 'standard' api create - when the api is only doing a $bao::create then use this
*
* @param string $bao_name Name of BAO Class
* @param array $params parameters passed into the api call
* @param string $entity Entity - pass in if entity is non-standard & required $ids array
*
* @throws API_Exception
* @return array
*/
function _civicrm_api3_basic_create($bao_name, &$params, $entity = NULL) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment