From: Matthias Schmidt Date: Tue, 27 Jun 2017 18:39:55 +0000 (+0200) Subject: Add direct links to article comment responses X-Git-Tag: 3.1.0_Alpha_1~319 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=6cb6558d3d0fb5357c6dc6a890c77a2609bb0900;p=GitHub%2FWoltLab%2FWCF.git Add direct links to article comment responses See #2223 --- diff --git a/wcfsetup/install/files/lib/system/user/activity/event/ArticleCommentResponseUserActivityEvent.class.php b/wcfsetup/install/files/lib/system/user/activity/event/ArticleCommentResponseUserActivityEvent.class.php index 11b667a6be..5801321c62 100644 --- a/wcfsetup/install/files/lib/system/user/activity/event/ArticleCommentResponseUserActivityEvent.class.php +++ b/wcfsetup/install/files/lib/system/user/activity/event/ArticleCommentResponseUserActivityEvent.class.php @@ -85,6 +85,8 @@ class ArticleCommentResponseUserActivityEvent extends SingletonFactory implement // title $text = WCF::getLanguage()->getDynamicVariable('wcf.article.recentActivity.articleCommentResponse', [ 'commentAuthor' => $users[$comment->userID], + 'commentID' => $comment->commentID, + 'responseID' => $response->responseID, 'article' => $article ]); $event->setTitle($text); diff --git a/wcfsetup/install/files/lib/system/user/activity/event/ArticleCommentUserActivityEvent.class.php b/wcfsetup/install/files/lib/system/user/activity/event/ArticleCommentUserActivityEvent.class.php index 6fdf660d58..f8cb03efd9 100644 --- a/wcfsetup/install/files/lib/system/user/activity/event/ArticleCommentUserActivityEvent.class.php +++ b/wcfsetup/install/files/lib/system/user/activity/event/ArticleCommentUserActivityEvent.class.php @@ -57,7 +57,10 @@ class ArticleCommentUserActivityEvent extends SingletonFactory implements IUserA $event->setIsAccessible(); // add title - $text = WCF::getLanguage()->getDynamicVariable('wcf.article.recentActivity.articleComment', ['article' => $article]); + $text = WCF::getLanguage()->getDynamicVariable('wcf.article.recentActivity.articleComment', [ + 'article' => $article, + 'commentID' => $comment->commentID + ]); $event->setTitle($text); // add text diff --git a/wcfsetup/install/lang/de.xml b/wcfsetup/install/lang/de.xml index dbee2c5f8a..5cb93de53a 100644 --- a/wcfsetup/install/lang/de.xml +++ b/wcfsetup/install/lang/de.xml @@ -2135,8 +2135,8 @@ Benutzerkontos nun in vollem Umfang nutzen.]]> comments} Kommentar{if $article->comments != 1}e{/if}]]> views} Mal gelesen]]> getLink()}">{$article->getTitle()}.]]> - getLink()}#comments">{$article->getTitle()} geschrieben.]]> - {$commentAuthor->username} zum Artikel {$article->getTitle()} geantwortet.]]> + getLink()}#comment{$commentID}">{$article->getTitle()} geschrieben.]]> + {$commentAuthor->username} zum Artikel {$article->getTitle()} geantwortet.]]> diff --git a/wcfsetup/install/lang/en.xml b/wcfsetup/install/lang/en.xml index 845a06d606..b30a12172c 100644 --- a/wcfsetup/install/lang/en.xml +++ b/wcfsetup/install/lang/en.xml @@ -2069,8 +2069,8 @@ full extend.]]> comments} Comment{if $article->comments != 1}s{/if}]]> views} View{if $article->views != 1}s{/if}]]> getLink()}">{$article->getTitle()}.]]> - getLink()}">{$article->getTitle()}.]]> - {$commentAuthor->username} on article {$article->getTitle()}.]]> + getLink()}#comment{$commentID}">{$article->getTitle()}.]]> + {$commentAuthor->username} on article {$article->getTitle()}.]]>