2020-06-07 19:04:43 +03:00
|
|
|
{extends "../@layout.xml"}
|
|
|
|
|
2022-08-09 09:37:08 +03:00
|
|
|
{block title}{_photo}{/block}
|
2020-06-07 19:04:43 +03:00
|
|
|
|
|
|
|
{block header}
|
|
|
|
{ifset $album}
|
2024-11-07 18:20:25 +03:00
|
|
|
{var $album_owner = $album->getOwner()}
|
|
|
|
<a href="{$album_owner->getURL()}">
|
|
|
|
{$album_owner->getCanonicalName()}
|
2020-06-07 19:04:43 +03:00
|
|
|
</a>
|
2024-11-07 18:20:25 +03:00
|
|
|
{if ($album_owner instanceof openvk\Web\Models\Entities\Club)}
|
|
|
|
» <a href="/albums{$album_owner->getId() * -1}">{_albums}</a>
|
2020-06-07 19:04:43 +03:00
|
|
|
{else}
|
2024-11-07 18:20:25 +03:00
|
|
|
» <a href="/albums{$album_owner->getId()}">{_albums}</a>
|
2020-06-07 19:04:43 +03:00
|
|
|
{/if}
|
|
|
|
» <a href="/album{$album->getPrettyId()}">{$album->getName()}</a>
|
|
|
|
{else}
|
2024-11-07 18:20:25 +03:00
|
|
|
<a href="{$owner->getURL()}">{$owner->getCanonicalName()}</a>
|
2020-06-07 19:04:43 +03:00
|
|
|
{/ifset}
|
2022-08-09 09:37:08 +03:00
|
|
|
» {_photo}
|
2020-06-07 19:04:43 +03:00
|
|
|
{/block}
|
|
|
|
|
|
|
|
{block content}
|
2024-11-07 18:20:25 +03:00
|
|
|
<div class='media-page-wrapper photo-page-wrapper'>
|
|
|
|
<div class='photo-page-wrapper-photo'>
|
|
|
|
<img src="{$photo->getURLBySizeId('large')}" />
|
2020-06-07 19:04:43 +03:00
|
|
|
</div>
|
2024-11-07 18:20:25 +03:00
|
|
|
|
|
|
|
<div class='ovk-photo-details'>
|
|
|
|
<div class='media-page-wrapper-description'>
|
|
|
|
<p n:if='!empty($photo->getDescription())'>{$photo->getDescription()}</p>
|
|
|
|
<div class='upload_time'>
|
|
|
|
{_info_upload_date}: {$photo->getPublicationTime()}
|
|
|
|
{if isset($thisUser)}
|
|
|
|
|
|
|
|
|
{var $liked = $photo->hasLikeFrom($thisUser)}
|
|
|
|
{var $likesCount = $photo->getLikesCount()}
|
|
|
|
<div class='like_wrap tidy'>
|
|
|
|
<a href="/photo{$photo->getPrettyId()}/like?hash={rawurlencode($csrfToken)}" class="post-like-button" data-liked="{(int) $liked}" data-likes="{$likesCount}">
|
|
|
|
<div class="heart" id="{if $liked}liked{/if}"></div>
|
|
|
|
<span class="likeCnt">{if $likesCount > 0}{$likesCount}{/if}</span>
|
|
|
|
</a>
|
|
|
|
</div>
|
|
|
|
{/if}
|
|
|
|
</div>
|
2020-06-07 19:04:43 +03:00
|
|
|
</div>
|
2023-08-11 16:50:19 +03:00
|
|
|
|
2024-11-07 18:20:25 +03:00
|
|
|
<hr/>
|
|
|
|
|
|
|
|
<div class="media-page-wrapper-details">
|
|
|
|
<div class='media-page-wrapper-comments'>
|
|
|
|
{include "../components/comments.xml", comments => $comments, count => $cCount, page => $cPage, model => "photos", parent => $photo, custom_id => 999}
|
|
|
|
</div>
|
|
|
|
<div class='media-page-wrapper-actions'>
|
|
|
|
<a href="{$owner->getURL()}" class='media-page-author-block'>
|
|
|
|
<img class='cCompactAvatars' src="{$owner->getAvatarURL('miniscule')}">
|
|
|
|
|
|
|
|
<div class='media-page-author-block-name'>
|
|
|
|
<b>{$owner->getCanonicalName()}</b>
|
|
|
|
</div>
|
|
|
|
</a>
|
|
|
|
<div n:if="isset($thisUser) && $thisUser->getId() === $photo->getOwner()->getId()">
|
|
|
|
<a href="/photo{$photo->getPrettyId()}/edit" class="profile_link" style="display:block;width:96%;">{_edit}</a>
|
|
|
|
<a id="_photoDelete" href="/photo{$photo->getPrettyId()}/delete" class="profile_link" style="display:block;width:96%;">{_delete}</a>
|
|
|
|
</div>
|
|
|
|
<a href="{$photo->getURL()}" class="profile_link" target="_blank" style="display:block;width:96%;">{_"open_original"}</a>
|
|
|
|
<a n:if="isset($thisUser) && $thisUser->getId() != $photo->getOwner()->getId()" class="profile_link" style="display:block;width:96%;" href="javascript:reportPhoto({$photo->getId()})">{_report}</a>
|
2024-11-07 19:18:17 +03:00
|
|
|
<a onclick="javascript:repost({$photo->getPrettyId()}, 'photo')" class="profile_link" style="display:block;width:96%;">
|
|
|
|
{_share}
|
|
|
|
</a>
|
2024-11-07 18:20:25 +03:00
|
|
|
</div>
|
|
|
|
</div>
|
2020-06-07 19:04:43 +03:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
{/block}
|