Skip to content

Commit 6a03e71

Browse files
Fix notification history to also work for role manager
For a manager no rule and rule esclatation exist, so left joins must be used
1 parent 75cf3c1 commit 6a03e71

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

library/Notifications/Model/NotificationHistory.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,8 @@
2424
*
2525
* @property int $id
2626
* @property ?int $incident_id
27-
* @property int $rule_id
28-
* @property int $rule_escalation_id
27+
* @property ?int $rule_id
28+
* @property ?int $rule_escalation_id
2929
* @property int $contact_id
3030
* @property ?int $contactgroup_id
3131
* @property int $channel_id
@@ -104,8 +104,8 @@ public function getDefaultSort(): array
104104

105105
public function createRelations(Relations $relations): void
106106
{
107-
$relations->belongsTo('rule', Rule::class);
108-
$relations->belongsTo('rule_escalation', RuleEscalation::class);
107+
$relations->belongsTo('rule', Rule::class)->setJoinType('LEFT');
108+
$relations->belongsTo('rule_escalation', RuleEscalation::class)->setJoinType('LEFT');
109109
$relations->belongsTo('contact', Contact::class);
110110

111111
$relations->belongsTo('incident', Incident::class)->setJoinType('LEFT');

0 commit comments

Comments
 (0)