<?php $user = cmsUser::getInstance(); ?>
<div class="cont_head margin-b10">
<?php html($ctype['title']); ?>
</div>
<div class="blogs-items-photo img-responsive-div">
<?php if (isset($fields['picture']) && $fields['picture']['is_in_list'] && !empty($item['picture'])){ ?> <a href="<?php echo href_to($ctype['name'], $item['slug'].'.html'); ?>">
<?php echo html_image($item['picture'], $fields['picture']['options']['size_teaser']); ?>
</a>
<?php } ?>
<div class="blogs-photo-info text-center
<?php if (isset($fields['picture']) && $fields['picture']['is_in_list'] && !empty($item['picture'])){ ?> blogs-photo-absolut
<?php } ?>">
<?php $autor = cmsCore::getModel('users')->getUser($item['user_id']);?>
<?php unset($item['picture']); ?> <a class="avatar-wheel display-i-b" href="<?php echo href_to('users', $item['user']['id']) ?>" title="<?php echo $item['user']['nickname']; ?>">
<?php echo html_avatar_image($autor['avatar'], 'micro');?>
</a>
<?php if ($item['parent_id']){ ?>
<div class="blogs-cat font-s16">
<a class="parent_title" href="<?php echo href_to($item['parent_url']); ?>">
<?php unset($item['parent_title']); ?> </a>
</div>
<?php } ?>
<h1 class="font-s22 margin-b10 font-bold color-tag-a">
<?php html($item['title']); ?>
<?php if ($item['is_private']) { ?>
<span class="is_private" title="<?php html(LANG_PRIVACY_PRIVATE); ?>"></span>
<?php } ?>
<?php unset($item['title']); ?> </h1>
</div>
</div>
<?php
$show_bar = $ctype['is_rating'] ||
$fields['date_pub']['is_in_item'] ||
$fields['user']['is_in_item'] ||
!empty($ctype['options']['hits_on']) || !$item['is_pub'] ||
!$item['is_approved'];
?>
<?php if ($show_bar){ ?>
<ul class="info_bar">
<?php if ($ctype['is_rating']){ ?>
<li class="bar_item bi_rating">
<?php echo $item['rating_widget']; ?>
</li>
<?php } ?>
<?php if ($fields['date_pub']['is_in_item']){ ?>
<li style="clear: both;" class="bar_item bi_date_pub" title="<?php html( $fields['date_pub']['title'] ); ?>">
<span aria-hidden="true" class="glyphicon glyphicon-calendar"></span>
<?php echo $fields['date_pub']['html']; ?>
</li>
<?php } ?>
<?php if (!$item['is_pub']){ ?>
<li class="bar_item bi_not_pub">
<?php echo LANG_CONTENT_NOT_IS_PUB; ?>
</li>
<?php } ?>
<?php if (!empty($ctype['options']['hits_on'])){ ?> <li class="bar_item bi_hits" title="<?php echo LANG_HITS; ?>">
<span aria-hidden="true" class="glyphicon glyphicon-eye-open"></span>
<?php echo $item['hits_count']; ?>
</li>
<?php } ?>
<?php if ($fields['user']['is_in_item']){ ?>
<li class="bar_item bi_user" title="<?php html( $fields['user']['title'] ); ?>">
<span class="glyphicon glyphicon-user"></span>
<?php echo $fields['user']['html']; ?>
</li>
<?php if (!empty($item['folder_title'])){ ?> <li class="bar_item bi_folder">
<span class="glyphicon glyphicon-folder-open"></span>
<a href="
<?php echo href_to
('users', $item['user']['id'], array('content', $ctype['name'], $item['folder_id'])); ?>">
<?php echo $item['folder_title']; ?></a>
</li>
<?php } ?>
<?php } ?>
<li class="bar_item bi_share">
<div class="share" style="margin:-4px">
<script type="text/javascript" src="//yandex.st/share/share.js" charset="utf-8"></script>
<div class="yashare-auto-init" data-yashareL10n="ru" data-yashareType="none" data-yashareQuickServices="yaru,vkontakte,facebook,twitter,odnoklassniki,moimir,lj,gplus"></div>
</div>
</li>
<?php if (!$item['is_approved']){ ?>
<li class="bar_item bi_not_approved">
<?php echo LANG_CONTENT_NOT_APPROVED; ?>
</li>
<?php } ?>
</ul>
<?php } ?>
<div class="content_item <?php echo $ctype['name']; ?>_item">
<?php foreach($fields as $name=>$field){ ?>
<?php if (!$field['is_in_item']) { continue; } ?>
<?php if ($field['is_system']) { continue; } ?>
<?php if (empty($item[$field['name']])) { continue; } ?> <?php if ($field['groups_read'] && !$user->isInGroups($field['groups_read'])) { continue; } ?>
<?php
if (!isset($field['options']['label_in_item'])) { $label_pos = 'none';
} else {
$label_pos = $field['options']['label_in_item'];
}
?>
<div class="field ft_<?php echo $field['type']; ?> f_<?php echo $field['name']; ?>">
<?php if ($label_pos != 'none'){ ?>
<div class="title_<?php echo $label_pos; ?>"><?php html($field['title']); ?>: </div>
<?php } ?>
<div class="value img-responsive-div">
<?php
echo $field['html'];
?>
</div>
</div>
<?php } ?>
<?php if ($props && $props_values) { ?>
<?php
$props_fields = $this->controller->getPropsFields($props);
$props_fieldsets = cmsForm::mapFieldsToFieldsets($props);
?>
<div class="content_item_props <?php echo $ctype['name']; ?>_item_props">
<table>
<tbody>
<?php foreach($props_fieldsets as $fieldset){ ?>
<?php if ($fieldset['title']){ ?>
<tr>
<td class="heading" colspan="2"><?php html($fieldset