Skip to content

Commit

Permalink
Add some weights to pcp page
Browse files Browse the repository at this point in the history
  • Loading branch information
eileenmcnaughton committed Oct 11, 2023
1 parent 6b2a937 commit 5780da7
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion CRM/PCP/Page/PCP.php
Original file line number Diff line number Diff line change
Expand Up @@ -54,37 +54,43 @@ public function &links() {
'url' => 'civicrm/pcp/info',
'qs' => 'action=update&reset=1&id=%%id%%&context=dashboard',
'title' => ts('Edit Personal Campaign Page'),
'weight' => CRM_Core_Action::getWeight(CRM_Core_Action::UPDATE),
],
CRM_Core_Action::RENEW => [
'name' => ts('Approve'),
'url' => 'civicrm/admin/pcp',
'qs' => 'action=renew&id=%%id%%',
'title' => ts('Approve Personal Campaign Page'),
'weight' => 30,
],
CRM_Core_Action::REVERT => [
'name' => ts('Reject'),
'url' => 'civicrm/admin/pcp',
'qs' => 'action=revert&id=%%id%%',
'title' => ts('Reject Personal Campaign Page'),
'weight' => 30,
],
CRM_Core_Action::DELETE => [
'name' => ts('Delete'),
'url' => 'civicrm/admin/pcp',
'qs' => 'action=delete&id=%%id%%',
'extra' => 'onclick = "return confirm(\'' . $deleteExtra . '\');"',
'title' => ts('Delete Personal Campaign Page'),
'weight' => CRM_Core_Action::getWeight(CRM_Core_Action::DELETE),
],
CRM_Core_Action::ENABLE => [
'name' => ts('Enable'),
'url' => 'civicrm/admin/pcp',
'qs' => 'action=enable&id=%%id%%',
'title' => ts('Enable'),
'weight' => CRM_Core_Action::getWeight(CRM_Core_Action::ENABLE),
],
CRM_Core_Action::DISABLE => [
'name' => ts('Disable'),
'url' => 'civicrm/admin/pcp',
'qs' => 'action=disable&id=%%id%%',
'title' => ts('Disable'),
'weight' => CRM_Core_Action::getWeight(CRM_Core_Action::DISABLE),
],
];
}
Expand Down Expand Up @@ -296,7 +302,7 @@ public function browse($action = NULL) {
'page_title' => $title,
'page_url' => $pageUrl,
'page_type' => $page_type,
'action' => CRM_Core_Action::formLink(self::links(), $action,
'action' => CRM_Core_Action::formLink($this->links(), $action,
['id' => $pcp->id], ts('more'), FALSE, 'contributionpage.pcp.list', 'PCP', $pcp->id
),
'title' => $pcp->title,
Expand Down

0 comments on commit 5780da7

Please sign in to comment.