Merge remote-tracking branch 'upstream/4.4' into 4.4-master-2014-08-25-10-57-01
authorkurund <kurund@civicrm.org>
Mon, 25 Aug 2014 05:30:50 +0000 (11:00 +0530)
committerkurund <kurund@civicrm.org>
Mon, 25 Aug 2014 05:30:50 +0000 (11:00 +0530)
Conflicts:
tests/phpunit/CiviTest/CiviUnitTestCase.php

1  2 
CRM/Activity/Import/Parser/Activity.php
CRM/Report/Form/Member/Detail.php
CRM/Utils/VersionCheck.php
api/v3/utils.php
templates/CRM/Contact/Form/Merge.tpl
templates/CRM/common/dedupe.tpl
tests/phpunit/CiviTest/CiviUnitTestCase.php
tests/phpunit/api/v3/ACLPermissionTest.php

Simple merge
Simple merge
Simple merge
index ae6eb0ac7cb2b4d3845ac3f52ad2775bba34f2f7,bf1fdb51475f6e29783675b71dfc1bcc53f3eaf4..3b9eb8dab7d00759ec9649889df18fee8579538d
  </div>
  
  <div class="action-link">
-        <a id='notDuplicate' href="#" title={ts}Mark this pair as not a duplicate.{/ts} onClick="processDupes( {$main_cid}, {$other_cid}, 'dupe-nondupe', 'merge-contact', '{crmURL p="civicrm/contact/dedupefind" q="reset=1&action=update&rgid=$rgid"}' );return false;">&raquo; {ts}Mark this pair as not a duplicate.{/ts}</a>
+        <a id='notDuplicate' href="#" title={ts}Mark this pair as not a duplicate.{/ts} onClick="processDupes( {$main_cid}, {$other_cid}, 'dupe-nondupe', 'merge-contact', '{if $rgid}{crmURL p="civicrm/contact/dedupefind" q="reset=1&action=update&rgid=$rgid"}{/if}' );return false;">&raquo; {ts}Mark this pair as not a duplicate.{/ts}</a>
  </div>
  
 -<table>
 +<table class="row-highlight">
    <tr class="columnheader">
      <th>&nbsp;</th>
 -    <th><a href="{crmURL p='civicrm/contact/view' q="reset=1&cid=$other_cid"}">{$other_name}&nbsp;<em>{$other_contact_subtype}</em></a> ({ts}duplicate{/ts})</th>
 +    <th><a href="{crmURL p='civicrm/contact/view' q="reset=1&cid=$other_cid"}">{$other_name}</a> ({ts}duplicate{/ts})</th>
      <th>{ts}Mark All{/ts}<br />=={$form.toggleSelect.html} ==&gt;</th>
 -    <th><a href="{crmURL p='civicrm/contact/view' q="reset=1&cid=$main_cid"}">{$main_name}&nbsp;<em>{$main_contact_subtype}</em></a></th>
 +    <th><a href="{crmURL p='civicrm/contact/view' q="reset=1&cid=$main_cid"}">{$main_name}</a></th>
    </tr>
    {foreach from=$rows item=row key=field}
       <tr class="{cycle values="odd-row,even-row"}">
Simple merge
index b6d5a62298cea411e39d254154117dcb3f0d0bb6,496ca2df3beed1a63e52715487571bdc3f71e26b..deb4d67c4975b7f1bd0c9b3d8aeed22ae27a0220
@@@ -2803,8 -2534,6 +2803,9 @@@ AND    ( TABLE_NAME LIKE 'civicrm_value
     *
     */
    function setupACL() {
 +    global $_REQUEST;
 +    $_REQUEST = $this->_params;
++    
      CRM_Core_Config::singleton()->userPermissionClass->permissions = array('access CiviCRM');
      $optionGroupID = $this->callAPISuccessGetValue('option_group', array('return' => 'id', 'name' => 'acl_role'));
      $optionValue = $this->callAPISuccess('option_value', 'create', array('option_group_id' => $optionGroupID,
      ));
      //flush cache
      CRM_ACL_BAO_Cache::resetCache();
 -      CRM_ACL_API::groupPermission('whatever', 9999, NULL, 'civicrm_saved_search', NULL, NULL, TRUE);
 +    CRM_Contact_BAO_Group::getPermissionClause(TRUE);
 +    CRM_ACL_API::groupPermission('whatever', 9999, NULL, 'civicrm_saved_search', NULL, NULL, TRUE);
 +  }
 +
 +  /**
 +   * alter default price set so that the field numbers are not all 1 (hiding errors)
 +   */
 +  function offsetDefaultPriceSet() {
 +    $contributionPriceSet = $this->callAPISuccess('price_set', 'getsingle', array('name' => 'default_contribution_amount'));
 +    $firstID = $contributionPriceSet['id'];
 +    $this->callAPISuccess('price_set', 'create', array('id' => $contributionPriceSet['id'], 'is_active' => 0, 'name' => 'old'));
 +    unset($contributionPriceSet['id']);
 +    $newPriceSet = $this->callAPISuccess('price_set', 'create', $contributionPriceSet);
 +    $priceField = $this->callAPISuccess('price_field', 'getsingle', array('price_set_id' => $firstID, 'options' => array('limit' => 1)));
 +    unset($priceField['id']);
 +    $priceField['price_set_id'] = $newPriceSet['id'];
 +    $newPriceField = $this->callAPISuccess('price_field', 'create', $priceField);
 +    $priceFieldValue = $this->callAPISuccess('price_field_value', 'getsingle', array('price_set_id' => $firstID, 'sequential' => 1, 'options' => array('limit' => 1)));
 +
 +    unset($priceFieldValue['id']);
 +    //create some padding to use up ids
 +    $this->callAPISuccess('price_field_value', 'create', $priceFieldValue);
 +    $this->callAPISuccess('price_field_value', 'create', $priceFieldValue);
 +    $this->callAPISuccess('price_field_value', 'create', array_merge($priceFieldValue, array('price_field_id' => $newPriceField['id'])));
    }
  
  /**