diff --git a/src/Content/Widget/VCard.php b/src/Content/Widget/VCard.php index d5a565f925..0d78fed4a4 100644 --- a/src/Content/Widget/VCard.php +++ b/src/Content/Widget/VCard.php @@ -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, ]); } } diff --git a/src/Model/Contact.php b/src/Model/Contact.php index 02132c0f1d..b6a3091532 100644 --- a/src/Model/Contact.php +++ b/src/Model/Contact.php @@ -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], ]; diff --git a/view/lang/de/strings.php b/view/lang/de/strings.php index e9c35e6669..90be1bd34c 100644 --- a/view/lang/de/strings.php +++ b/view/lang/de/strings.php @@ -2963,4 +2963,4 @@ $a->strings['Last users'] = 'Letzte Nutzer'; $a->strings['Quick Start'] = 'Schnell-Start'; $a->strings['Mention'] = 'Erwähne'; $a->strings['Post to group'] = 'In Gruppe posten'; - +$a->strings['View group'] = 'Zeige Gruppe'; diff --git a/view/templates/hovercard.tpl b/view/templates/hovercard.tpl index 0fdcffaf24..41236459a8 100644 --- a/view/templates/hovercard.tpl +++ b/view/templates/hovercard.tpl @@ -25,6 +25,7 @@ {{if $profile.addr && !$profile.actions.self}}{{/if}}
+ {{if $profile.actions.group.2==1}}{{/if}} {{if $profile.actions.network}}{{/if}} {{if $profile.actions.edit}}{{/if}} {{if $profile.actions.follow}}{{/if}} diff --git a/view/theme/frio/templates/widget/vcard.tpl b/view/theme/frio/templates/widget/vcard.tpl index ecc47bea29..5266f5be4e 100644 --- a/view/theme/frio/templates/widget/vcard.tpl +++ b/view/theme/frio/templates/widget/vcard.tpl @@ -64,6 +64,14 @@
{{/if}} + {{if $contact.forum==1 || $contact.prv==1}} +
+ +
+ {{/if}}