Merge branch 'showgroup-button' into better-navigation
This commit is contained in:
@@ -68,6 +68,7 @@ class VCard
|
||||
$follow_link = '';
|
||||
$unfollow_link = '';
|
||||
$wallmessage_link = '';
|
||||
$showgroup_link = '';
|
||||
|
||||
$photo = Contact::getPhoto($contact);
|
||||
|
||||
@@ -99,6 +100,10 @@ class VCard
|
||||
if (in_array($rel, [Contact::FOLLOWER, Contact::FRIEND]) && Contact::canReceivePrivateMessages($contact)) {
|
||||
$wallmessage_link = 'message/new/' . $id;
|
||||
}
|
||||
|
||||
if (in_array($rel, [Contact::SHARING])) {
|
||||
$showgroup_link = 'network/group/' . $id;
|
||||
}
|
||||
}
|
||||
|
||||
return Renderer::replaceMacros(Renderer::getMarkupTemplate('widget/vcard.tpl'), [
|
||||
@@ -121,6 +126,8 @@ class VCard
|
||||
'$wallmessage_link' => $wallmessage_link,
|
||||
'$mentioning' => DI::l10n()->t('Mention'),
|
||||
'$post2group' => DI::l10n()->t('Post to group'),
|
||||
'$showgroup' => DI::l10n()->t('Show group'),
|
||||
'$showgroup_link' => $showgroup_link,
|
||||
]);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1246,9 +1246,9 @@ class Contact
|
||||
'network' => [DI::l10n()->t('Network Posts'), $posts_link, false],
|
||||
'edit' => [DI::l10n()->t('View Contact'), $contact_url, false],
|
||||
'pm' => [DI::l10n()->t('Send PM'), $pm_url, false],
|
||||
'mention' => [DI::l10n()->t('Mention'), DI::l10n()->t('Post to group'), $mention_url, false],
|
||||
'follow' => [DI::l10n()->t('Connect/Follow'), $follow_link, true],
|
||||
'unfollow' => [DI::l10n()->t('Unfollow'), $unfollow_link, true],
|
||||
'mention' => [DI::l10n()->t('Mention'), DI::l10n()->t('Post to group'), $mention_url, false],
|
||||
'group' => [DI::l10n()->t('View group'), $group_link, $contact['forum'], true],
|
||||
'self' => [$self],
|
||||
];
|
||||
|
||||
Reference in New Issue
Block a user