[Reports] Возможность перейти к посту из комментария (#965)

ПОРНО
This commit is contained in:
n1rwana 2023-08-15 02:12:48 +03:00 committed by GitHub
parent a2c5896fa1
commit 1174ddfa4f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 7 additions and 2 deletions

View file

@ -16,7 +16,7 @@
{elseif $type == "group" || $type == "user"} {elseif $type == "group" || $type == "user"}
{include "../components/group.xml", group => $object, isUser => $type == "user"} {include "../components/group.xml", group => $object, isUser => $type == "user"}
{elseif $type == "comment"} {elseif $type == "comment"}
{include "../components/comment.xml", comment => $object, timeOnly => true} {include "../components/comment.xml", comment => $object, timeOnly => true, linkWithPost => true}
{elseif $type == "note"} {elseif $type == "note"}
{include "./content/note.xml", note => $object} {include "./content/note.xml", note => $object}
{elseif $type == "app"} {elseif $type == "app"}

View file

@ -29,7 +29,12 @@
</div> </div>
</div> </div>
<div n:if="isset($thisUser) &&! ($compact ?? false)" class="post-menu"> <div n:if="isset($thisUser) &&! ($compact ?? false)" class="post-menu">
<a href="#_comment{$comment->getId()}" class="date">{$comment->getPublicationTime()}</a> <a
href="{=$linkWithPost && get_class($comment->getTarget()) == 'openvk\Web\Models\Entities\Post' ? '/wall' . $comment->getTarget()->getPrettyId() : ''}#_comment{$comment->getId()}"
class="date"
>
{$comment->getPublicationTime()}
</a>
{if !$timeOnly} {if !$timeOnly}
&nbsp;| &nbsp;|
{if $comment->canBeDeletedBy($thisUser)} {if $comment->canBeDeletedBy($thisUser)}