);
}
- // add the recently created Grant
+ // add the recently created Grant
CRM_Utils_Recent::add($title,
$url,
$grant->id,
);
$fields = CRM_Grant_DAO_Grant::export();
- $grantNote = array('grant_note' => array('title' => ts('Grant Note'),
+ $grantNote = array(
+ 'grant_note' => array(
+ 'title' => ts('Grant Note'),
'name' => 'grant_note',
'data_type' => CRM_Utils_Type::T_TEXT,
));
* @param $row
* @param int $id
*/
- public static function searchAction(&$row, $id) {}
+ public static function searchAction(&$row, $id) {
+ }
/**
* @param $tables
*/
- public static function tableNames(&$tables) {}
+ public static function tableNames(&$tables) {
+ }
}
$this->assign('note', CRM_Core_DAO::getFieldValue('CRM_Core_DAO_Note', $this->_noteId, 'note'));
}
-
// add Grant to Recent Items
$url = CRM_Utils_System::url('civicrm/contact/view/grant',
"action=view&reset=1&id={$values['id']}&cid={$values['contact_id']}&context=home"
);
}
-
$selector = new CRM_Grant_Selector_Search($this->_queryParams,
$this->_action,
NULL,
}
else {
$queryParams = $form->get('queryParams');
- $sortOrder = null;
+ $sortOrder = NULL;
if ( $form->get( CRM_Utils_Sort::SORT_ORDER ) ) {
$sortOrder = $form->get( CRM_Utils_Sort::SORT_ORDER );
}
* @return array
*/
public function registerTab() {
- return array('title' => ts('Grants'),
+ return array(
+ 'title' => ts('Grants'),
'url' => 'grant',
'weight' => 50,
);
* @return array
*/
public function registerAdvancedSearchPane() {
- return array('title' => ts('Grants'),
+ return array(
+ 'title' => ts('Grants'),
'weight' => 50,
);
}
CRM_Core_Permission::check('edit grants')
) {
$shortCuts = array_merge($shortCuts, array(
- array('path' => 'civicrm/grant/add',
+ array(
+ 'path' => 'civicrm/grant/add',
'query' => "reset=1&action=add&context=standalone",
'ref' => 'new-grant',
'title' => ts('Grant'),
@access public
*/
function __construct(&$queryParams,
- $action = CRM_Core_Action::NONE,
+ $action = CRM_Core_Action::NONE,
$grantClause = NULL,
- $single = FALSE,
- $limit = NULL,
- $context = 'search'
+ $single = FALSE,
+ $limit = NULL,
+ $context = 'search'
) {
// submitted form values
$this->_queryParams = &$queryParams;
-
$this->_single = $single;
$this->_limit = $limit;
$this->_context = $context;
if ($cid) {
$delLink = array(
- CRM_Core_Action::DELETE => array('name' => ts('Delete'),
+ CRM_Core_Action::DELETE => array(
+ 'name' => ts('Delete'),
'url' => 'civicrm/contact/view/grant',
'qs' => 'action=delete&reset=1&cid=%%cid%%&id=%%id%%&selectedChild=grant' . $extraParams,
'title' => ts('Delete Grant'),
$result->grant_id
);
- $row['contact_type'] = CRM_Contact_BAO_Contact_Utils::getImage($result->contact_sub_type ?
- $result->contact_sub_type : $result->contact_type, FALSE, $result->contact_id
+ $row['contact_type'] = CRM_Contact_BAO_Contact_Utils::getImage($result->contact_sub_type ? $result->contact_sub_type : $result->contact_type, FALSE, $result->contact_id
);
$rows[] = $row;
public function &getColumnHeaders($action = NULL, $output = NULL) {
if (!isset(self::$_columnHeaders)) {
self::$_columnHeaders = array(
- array('name' => ts('Status'),
+ array(
+ 'name' => ts('Status'),
'sort' => 'grant_status',
'direction' => CRM_Utils_Sort::DONTCARE,
),
*/
public static function &tasks() {
if (!(self::$_tasks)) {
- self::$_tasks = array(1 => array(
+ self::$_tasks = array(
+ 1 => array(
'title' => ts('Delete Grants'),
'class' => 'CRM_Grant_Form_Task_Delete',
'result' => FALSE,