CRM_Case_XMLProcessor_Process
class CRM_Case_XMLProcessor_Process extends CRM_Case_XMLProcessor
Properties
static array|null | $activityTypes | FIXME: This does NOT belong in a static property, but we're too late in the 4.5-cycle to do the necessary cleanup. | from CRM_Case_XMLProcessor |
protected | $defaultAssigneeOptionsValues |
Methods
This function was previously used to convert a case-type's machine-name to a file-name. However, it's mind-boggling that the file-name might be a munged version of the machine-name (which is itself a munged version of the display-name), and naming is now a more visible issue (since the overhaul of CaseType admin UI).
No description
Get all relationship type display labels (not machine names)
Run.
No description
No description
No description
No description
No description
No description
No description
Relationships are straight from XML, described from perspective of non-client
No description
No description
No description
Return the default assignee contact for the activity.
Fetches and caches the activity's default assignee options.
Returns the default assignee for the activity by searching for the target's contact relationship type defined in the activity's details.
Determines if the given relationship type is bidirectional or not by comparing their labels.
Returns the activity's default assignee for a specific contact if the contact exists, otherwise returns null.
No description
No description
No description
No description
No description
Retrieves AllowMultipleCaseClients setting.
Retrieves NaturalActivityTypeSort setting.
Details
in CRM_Case_XMLProcessor at line 50
FALSE|SimpleXMLElement
retrieve($caseType)
in CRM_Case_XMLProcessor at line 73
static string
mungeCaseType(string $caseType)
deprecated
deprecated
This function was previously used to convert a case-type's machine-name to a file-name. However, it's mind-boggling that the file-name might be a munged version of the machine-name (which is itself a munged version of the display-name), and naming is now a more visible issue (since the overhaul of CaseType admin UI).
Usage note: This is called externally by civix stubs as a sort of side-ways validation of the case-type's name (validation which was needed because of the unintuitive double-munge). We should update civix templates and then remove this function in Civi 4.6 or 5.0.
in CRM_Case_XMLProcessor at line 86
array
allActivityTypes(bool $indexName = TRUE, bool $all = FALSE)
in CRM_Case_XMLProcessor at line 105
array
allRelationshipTypes(bool $fromXML = FALSE)
Get all relationship type display labels (not machine names)
in CRM_Case_XMLProcessor at line 137
static
flushStaticCaches()
FIXME: This should not exist
at line 45
bool
run(string $caseType, array $params)
Run.
at line 71
array|bool|mixed
get($caseType, $fieldSet, bool $isLabel = FALSE, bool $maskAction = FALSE)
at line 99
process($xml, array $params)
at line 150
processStandardTimeline($activitySetXML, array $params)
at line 169
processActivitySet($activitySetXML, array $params)
at line 183
array|mixed
caseRoles($caseRolesXML, bool $isCaseManager = FALSE)
at line 215
bool
createRelationships(SimpleXMLElement $relationshipTypeXML, array $params)
at line 263
bool
createRelationship(array $params)
at line 281
array
activityTypes($activityTypesXML, bool $maxInst = FALSE, bool $isLabel = FALSE, bool $maskAction = FALSE)
at line 327
array
getDeclaredActivityTypes(SimpleXMLElement $caseTypeXML)
at line 358
array
getDeclaredRelationshipTypes(SimpleXMLElement $caseTypeXML)
Relationships are straight from XML, described from perspective of non-client
at line 376
deleteEmptyActivity(array $params)
at line 400
bool
isActivityPresent(array $params)
at line 431
bool
createActivity($activityTypeXML, array $params)
at line 593
protected int|null
getDefaultAssigneeForActivity(array $activityParams, object $activityTypeXML)
Return the default assignee contact for the activity.
at line 624
protected array
getDefaultAssigneeOptionValues()
Fetches and caches the activity's default assignee options.
at line 650
protected int|null
getDefaultAssigneeByRelationship(array $activityParams, object $activityTypeXML)
Returns the default assignee for the activity by searching for the target's contact relationship type defined in the activity's details.
at line 695
protected bool
isBidirectionalRelationshipType($relationshipTypeId)
Determines if the given relationship type is bidirectional or not by comparing their labels.
at line 718
protected int|null
getDefaultAssigneeBySpecificContact(object $activityTypeXML)
Returns the activity's default assignee for a specific contact if the contact exists, otherwise returns null.
at line 739
static array
activitySets($activitySetsXML)
at line 759
array|bool|mixed
getMaxInstance($caseType, null $activityTypeName = NULL)
at line 776
array|mixed
getCaseManagerRoleId($caseType)
at line 786
CaseChangeListener>
getListeners(string $caseType)
at line 801
int
getRedactActivityEmail()
at line 811
string
getAllowMultipleCaseClients()
Retrieves AllowMultipleCaseClients setting.
at line 821
string
getNaturalActivityTypeSort()
Retrieves NaturalActivityTypeSort setting.
at line 856
array[bool|string,string]
locateNameOrLabel(SimpleXMLElement $xml)
At some point name and label got mixed up for case roles.
Check against known machine name values, and then if no match check against labels. This is subject to some edge cases, but we catch those with a system status check. We do this to avoid requiring people to update their xml files which can be stored in external files we can't/don't want to edit.