projects
/
civicrm-core.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge pull request #4291 from mrpaulc/CRM-12920
[civicrm-core.git]
/
CRM
/
Contribute
/
Selector
/
Search.php
diff --git
a/CRM/Contribute/Selector/Search.php
b/CRM/Contribute/Selector/Search.php
index 4de248ae38fa959558078cfc7db1fde6df5eca6b..6c96eba78e13d803dcdec2a193a37834019d360f 100644
(file)
--- a/
CRM/Contribute/Selector/Search.php
+++ b/
CRM/Contribute/Selector/Search.php
@@
-158,13
+158,16
@@
class CRM_Contribute_Selector_Search extends CRM_Core_Selector_Base implements C
* Class constructor
*
* @param array $queryParams array of parameters for query
* Class constructor
*
* @param array $queryParams array of parameters for query
- * @param
int
$action - action of search basic or advanced.
- * @param string
$contributionClause if the caller wants to further restrict the search (used in contributions)
+ * @param
\const|int
$action - action of search basic or advanced.
+ * @param string $contributionClause if the caller wants to further restrict the search (used in contributions)
* @param boolean $single are we dealing only with one contact?
* @param boolean $single are we dealing only with one contact?
- * @param int
$limit
how many contributions do we want returned
+ * @param int
$limit
how many contributions do we want returned
*
*
- * @return CRM_Contact_Selector
- * @access public
+ * @param string $context
+ * @param null $compContext
+ *
+ * @return \CRM_Contribute_Selector_Search
+ @access public
*/
function __construct(&$queryParams,
$action = CRM_Core_Action::NONE,
*/
function __construct(&$queryParams,
$action = CRM_Core_Action::NONE,
@@
-215,9
+218,13
@@
class CRM_Contribute_Selector_Search extends CRM_Core_Selector_Base implements C
* - View
* - Edit
*
* - View
* - Edit
*
+ * @param null $componentId
+ * @param null $componentAction
+ * @param null $key
+ * @param null $compContext
+ *
* @return array
* @access public
* @return array
* @access public
- *
*/
static function &links($componentId = NULL, $componentAction = NULL, $key = NULL, $compContext = NULL) {
$extraParams = NULL;
*/
static function &links($componentId = NULL, $componentAction = NULL, $key = NULL, $compContext = NULL) {
$extraParams = NULL;
@@
-260,7
+267,9
@@
class CRM_Contribute_Selector_Search extends CRM_Core_Selector_Base implements C
/**
* getter for array of the parameters required for creating pager.
*
/**
* getter for array of the parameters required for creating pager.
*
- * @param
+ * @param $action
+ * @param $params
+ * @internal param $
* @access public
*/
function getPagerParams($action, &$params) {
* @access public
*/
function getPagerParams($action, &$params) {
@@
-450,9
+459,9
@@
class CRM_Contribute_Selector_Search extends CRM_Core_Selector_Base implements C
),
);
if ($this->_includeSoftCredits) {
),
);
if ($this->_includeSoftCredits) {
- self::$_columnHeaders =
+ self::$_columnHeaders =
array_merge(
array_merge(
- self::$_columnHeaders,
+ self::$_columnHeaders,
array(
array(
'name' => ts('Soft Credit Amount'),
array(
array(
'name' => ts('Soft Credit Amount'),
@@
-462,13
+471,13
@@
class CRM_Contribute_Selector_Search extends CRM_Core_Selector_Base implements C
)
);
}
)
);
}
- self::$_columnHeaders =
+ self::$_columnHeaders =
array_merge(
array_merge(
- self::$_columnHeaders,
+ self::$_columnHeaders,
array(
array(
'name' => ts('Type'),
array(
array(
'name' => ts('Type'),
- 'sort' => 'financial_type
_id
',
+ 'sort' => 'financial_type',
'direction' => CRM_Utils_Sort::DONTCARE,
),
array(
'direction' => CRM_Utils_Sort::DONTCARE,
),
array(
@@
-488,7
+497,7
@@
class CRM_Contribute_Selector_Search extends CRM_Core_Selector_Base implements C
),
array(
'name' => ts('Status'),
),
array(
'name' => ts('Status'),
- 'sort' => 'contribution_status
_id
',
+ 'sort' => 'contribution_status',
'direction' => CRM_Utils_Sort::DONTCARE,
),
array(
'direction' => CRM_Utils_Sort::DONTCARE,
),
array(
@@
-510,9
+519,9
@@
class CRM_Contribute_Selector_Search extends CRM_Core_Selector_Base implements C
self::$_columnHeaders = array_merge($pre, self::$_columnHeaders);
}
if ($this->_includeSoftCredits) {
self::$_columnHeaders = array_merge($pre, self::$_columnHeaders);
}
if ($this->_includeSoftCredits) {
- self::$_columnHeaders =
+ self::$_columnHeaders =
array_merge(
array_merge(
- self::$_columnHeaders,
+ self::$_columnHeaders,
array(
array(
'name' => ts('Soft Credit For'),
array(
array(
'name' => ts('Soft Credit For'),
@@
-527,7
+536,7
@@
class CRM_Contribute_Selector_Search extends CRM_Core_Selector_Base implements C
)
);
}
)
);
}
- self::$_columnHeaders =
+ self::$_columnHeaders =
array_merge(
self::$_columnHeaders, array(
array('desc' => ts('Actions'))
array_merge(
self::$_columnHeaders, array(
array('desc' => ts('Actions'))
@@
-536,10
+545,16
@@
class CRM_Contribute_Selector_Search extends CRM_Core_Selector_Base implements C
return self::$_columnHeaders;
}
return self::$_columnHeaders;
}
+ /**
+ * @return mixed
+ */
function alphabetQuery() {
return $this->_query->searchQuery(NULL, NULL, NULL, FALSE, FALSE, TRUE);
}
function alphabetQuery() {
return $this->_query->searchQuery(NULL, NULL, NULL, FALSE, FALSE, TRUE);
}
+ /**
+ * @return string
+ */
function &getQuery() {
return $this->_query;
}
function &getQuery() {
return $this->_query;
}
@@
-555,6
+570,9
@@
class CRM_Contribute_Selector_Search extends CRM_Core_Selector_Base implements C
return ts('CiviCRM Contribution Search');
}
return ts('CiviCRM Contribution Search');
}
+ /**
+ * @return mixed
+ */
function getSummary() {
return $this->_query->summaryContribution($this->_context);
}
function getSummary() {
return $this->_query->summaryContribution($this->_context);
}