mirror of
https://github.com/humhub/humhub.git
synced 2025-01-16 21:58:17 +01:00
Fix #2558: No notification for user profile posts send
This commit is contained in:
parent
b7d2b0a0cf
commit
0fd985e6fe
@ -23,6 +23,8 @@ HumHub Change Log
|
||||
- Fix: Send button text on request space membership dialog
|
||||
- Fix #2555: Friendship notification category visible even if friendship system deactivated
|
||||
- Enh: Don't auto focus space chooser search on small devices
|
||||
- Fix #2612: Single list item hides markers
|
||||
- Fix #2558: No notification for user profile posts send
|
||||
|
||||
1.2.0 (April 16, 2017)
|
||||
--------------------------------
|
||||
|
@ -43,10 +43,18 @@ class ContentCreated extends \humhub\modules\notification\components\BaseNotific
|
||||
*/
|
||||
public function html()
|
||||
{
|
||||
return Yii::t('ContentModule.notifications_views_ContentCreated', '{displayName} created {contentTitle}.', [
|
||||
'displayName' => Html::tag('strong', Html::encode($this->originator->displayName)),
|
||||
'contentTitle' => $this->getContentInfo($this->source)
|
||||
]);
|
||||
if($this->source->content->container instanceof User && $this->record->user->is($this->source->content->container)) {
|
||||
return Yii::t('ContentModule.notifications_views_ContentCreated', '{displayName} posted on your profile {contentTitle}.', [
|
||||
'displayName' => Html::tag('strong', Html::encode($this->originator->displayName)),
|
||||
'contentTitle' => $this->getContentInfo($this->source, false)
|
||||
]);
|
||||
} else {
|
||||
return Yii::t('ContentModule.notifications_views_ContentCreated', '{displayName} created {contentTitle}.', [
|
||||
'displayName' => Html::tag('strong', Html::encode($this->originator->displayName)),
|
||||
'contentTitle' => $this->getContentInfo($this->source)
|
||||
]);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -206,6 +206,7 @@ class NotificationManager
|
||||
// Note the notification follow logic for users is currently not implemented.
|
||||
// TODO: perhaps return only friends if public is false?
|
||||
$result = (!$public) ? [] : Follow::getFollowersQuery($container, true)->all();
|
||||
$result[] = $container;
|
||||
}
|
||||
return $result;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user