Skip to content

Commit

Permalink
CRM-20424 remove call to deprecated function.
Browse files Browse the repository at this point in the history
This is the one covering the UI with errors. The fact it did not cause any test fails means it is
not covered by unit tests :-(.

As long as the Open Case link is still present for CiviCase users this is working
  • Loading branch information
eileenmcnaughton committed Apr 26, 2017
1 parent c85b067 commit bf94d03
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions CRM/Case/Info.php
Original file line number Diff line number Diff line change
Expand Up @@ -212,15 +212,12 @@ public function creatNewShortcut(&$shortCuts) {
if (CRM_Core_Permission::check('access all cases and activities') ||
CRM_Core_Permission::check('add cases')
) {
$atype = CRM_Core_OptionGroup::getValue('activity_type',
'Open Case',
'name'
);
if ($atype) {
$activityType = CRM_Core_PseudoConstant::getLabel('CRM_Activity_BAO_Activity', 'activity_type_id', 'Open Case');
if ($activityType) {
$shortCuts = array_merge($shortCuts, array(
array(
'path' => 'civicrm/case/add',
'query' => "reset=1&action=add&atype=$atype&context=standalone",
'query' => "reset=1&action=add&atype={$activityType}&context=standalone",
'ref' => 'new-case',
'title' => ts('Case'),
),
Expand Down

0 comments on commit bf94d03

Please sign in to comment.