Skip to content

Commit

Permalink
COMCL-603: Update case type entity name as that has been updated in c…
Browse files Browse the repository at this point in the history
…ivicrm core
  • Loading branch information
Muhammad Shahrukh committed Jul 15, 2024
1 parent eaefbbd commit 0a82f75
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion civicase.php
Original file line number Diff line number Diff line change
Expand Up @@ -542,7 +542,9 @@ function civicase_civicrm_alterAngular(Manager $angular) {
* Entity types array.
*/
function _civicase_add_case_category_case_type_entity(array &$entityTypes) {
$entityTypes['CRM_Case_DAO_CaseType']['fields_callback'][] = function ($class, &$fields) {
$caseTypeEntityName = isset($entityTypes['CRM_Case_DAO_CaseType']) ? 'CRM_Case_DAO_CaseType' : 'CaseType';

$entityTypes[$caseTypeEntityName]['fields_callback'][] = function ($class, &$fields) {
$fields['case_type_category'] = [
'name' => 'case_type_category',
'type' => CRM_Utils_Type::T_INT,
Expand Down

0 comments on commit 0a82f75

Please sign in to comment.