mirror of
https://github.com/Oreolek/ifhub.club.git
synced 2024-07-09 01:44:25 +03:00
86 lines
2.5 KiB
Smarty
86 lines
2.5 KiB
Smarty
{**
|
|
* Топик фотосет
|
|
*
|
|
* @styles css/topic.css
|
|
*}
|
|
|
|
{extends file='topics/topic_base.tpl'}
|
|
|
|
|
|
{* Preview Image *}
|
|
{block name='topic_header_after'}
|
|
{$oMainPhoto = $oTopic->getPhotosetMainPhoto()}
|
|
|
|
{if $oMainPhoto}
|
|
<div class="topic-preview-image">
|
|
<div class="topic-preview-image-inner js-topic-preview-loader loading" onclick="window.location='{$oTopic->getUrl()}'">
|
|
<div class="topic-preview-image-count" id="photoset-photo-count-{$oTopic->getId()}"><i class="icon-camera icon-white"></i> {$oTopic->getPhotosetCount()}</div>
|
|
|
|
{if $oMainPhoto->getDescription()}
|
|
<div class="topic-preview-image-desc" id="photoset-photo-desc-{$oTopic->getId()}">{$oMainPhoto->getDescription()}</div>
|
|
{/if}
|
|
|
|
<img class="js-topic-preview-image" src="{$oMainPhoto->getWebPath(1000)}" alt="Topic preview" />
|
|
</div>
|
|
</div>
|
|
{/if}
|
|
{/block}
|
|
|
|
|
|
{* Текст *}
|
|
{block name='topic_content_text'}
|
|
{if $bTopicList}
|
|
{$oTopic->getTextShort()}
|
|
|
|
{if $oTopic->getTextShort() != $oTopic->getText()}
|
|
{$iPhotosCount = $oTopic->getPhotosetCount()}
|
|
|
|
<br />
|
|
<a href="{$oTopic->getUrl()}#cut" title="{$aLang.topic_read_more}">
|
|
{if $oTopic->getCutText()}
|
|
{$oTopic->getCutText()}
|
|
{else}
|
|
{$aLang.topic_photoset_show_all|ls_lang:"COUNT%%`$iPhotosCount`"} →
|
|
{/if}
|
|
</a>
|
|
{/if}
|
|
{else}
|
|
{$oTopic->getText()}
|
|
{/if}
|
|
{/block}
|
|
|
|
|
|
{* Photoset *}
|
|
{block name='topic_content_after'}
|
|
{if ! $bTopicList}
|
|
<div class="photoset photoset-type-default">
|
|
<h2 class="photoset-title">{$oTopic->getPhotosetCount()} {$oTopic->getPhotosetCount()|declension:$aLang.topic_photoset_count_images}</h2>
|
|
|
|
<ul class="photoset-images" id="topic-photo-images">
|
|
{$aPhotos = $oTopic->getPhotosetPhotos(0, $oConfig->get('module.topic.photoset.per_page'))}
|
|
|
|
{if $aPhotos}
|
|
{foreach $aPhotos as $oPhoto}
|
|
<li>
|
|
<a class="js-photoset-type-default-image"
|
|
href="{$oPhoto->getWebPath(1000)}"
|
|
rel="[photoset]" title="{$oPhoto->getDescription()}">
|
|
|
|
<img src="{$oPhoto->getWebPath('50crop')}" alt="{$oPhoto->getDescription()}" /></a>
|
|
</li>
|
|
|
|
{$iLastPhotoId = $oPhoto->getId()}
|
|
{/foreach}
|
|
{/if}
|
|
|
|
<script type="text/javascript">
|
|
ls.photoset.idLast='{$iLastPhotoId}';
|
|
</script>
|
|
</ul>
|
|
|
|
{if count($aPhotos) < $oTopic->getPhotosetCount()}
|
|
<a href="javascript:ls.photoset.getMore({$oTopic->getId()})" id="topic-photo-more" class="get-more">{$aLang.topic_photoset_show_more} ↓</a>
|
|
{/if}
|
|
</div>
|
|
{/if}
|
|
{/block} |