mirror of
https://github.com/humhub/humhub.git
synced 2025-01-17 22:28:51 +01:00
Update TopicLabel.php
This commit is contained in:
parent
730d6f300f
commit
ed70e61242
@ -1,4 +1,5 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* @link https://www.humhub.org/
|
||||
* @copyright Copyright (c) 2018 HumHub GmbH & Co. KG
|
||||
@ -8,7 +9,6 @@
|
||||
|
||||
namespace humhub\modules\topic\widgets;
|
||||
|
||||
|
||||
use humhub\modules\content\models\ContentTag;
|
||||
use humhub\modules\topic\models\Topic;
|
||||
use humhub\widgets\Label;
|
||||
@ -20,6 +20,7 @@ class TopicLabel extends Label
|
||||
public static function forTopic(Topic $topic)
|
||||
{
|
||||
$link = Link::withAction('', 'topic.addTopic')->options(['data-topic-id' => $topic->id, 'data-topic-url' => $topic->getUrl()]);
|
||||
|
||||
return static::defaultType($topic->name)->sortOrder(20)->color($topic->color)->withLink($link)->icon('fa-star');
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user