mirror of
https://github.com/Oreolek/ifhub.club.git
synced 2024-06-28 20:45:00 +03:00
Доработка компонентов
This commit is contained in:
parent
c2d60a7051
commit
ed1278b66b
|
@ -126,12 +126,12 @@ class ActionBlogs extends Action
|
|||
* Формируем и возвращает ответ
|
||||
*/
|
||||
$oViewer = $this->Viewer_GetLocalViewer();
|
||||
$oViewer->Assign('aBlogs', $aResult['collection']);
|
||||
$oViewer->Assign('blogs', $aResult['collection'], true);
|
||||
$oViewer->Assign('oUserCurrent', $this->User_GetUserCurrent());
|
||||
$oViewer->Assign('sBlogsEmptyList', $this->Lang_Get('search.alerts.empty'));
|
||||
$oViewer->Assign('bUseMore', true);
|
||||
$oViewer->Assign('bHideMore', $bHideMore);
|
||||
$oViewer->Assign('iSearchCount', $aResult['count']);
|
||||
$oViewer->Assign('textEmpty', $this->Lang_Get('search.alerts.empty'), true);
|
||||
$oViewer->Assign('useMore', true, true);
|
||||
$oViewer->Assign('hideMore', $bHideMore, true);
|
||||
$oViewer->Assign('searchCount', $aResult['count'], true);
|
||||
$this->Viewer_AssignAjax('sText', $oViewer->Fetch("components/blog/blog-list.tpl"));
|
||||
/**
|
||||
* Для подгрузки
|
||||
|
|
|
@ -25,7 +25,7 @@
|
|||
* @package application.blocks
|
||||
* @since 2.0
|
||||
*/
|
||||
class BlockCategoryUpdate extends Block
|
||||
class BlockFieldCategory extends Block
|
||||
{
|
||||
/**
|
||||
* Запуск обработки
|
|
@ -57,7 +57,7 @@ return array(
|
|||
/**
|
||||
* Голосование
|
||||
*/
|
||||
'vote' => array(
|
||||
'vote' => array(
|
||||
'up' => 'Нравится',
|
||||
'down' => 'Не нравится',
|
||||
'abstain' => 'Воздержаться от голосования и посмотреть рейтинг',
|
||||
|
@ -108,7 +108,7 @@ return array(
|
|||
/**
|
||||
* Сортировка
|
||||
*/
|
||||
'sort' => array(
|
||||
'sort' => array(
|
||||
'label' => 'Сортировать',
|
||||
'by_login' => 'по логину',
|
||||
'by_name' => 'по имени',
|
||||
|
@ -130,7 +130,7 @@ return array(
|
|||
/**
|
||||
* Блог
|
||||
*/
|
||||
'blog' => array(
|
||||
'blog' => array(
|
||||
'blog' => 'Блог',
|
||||
'blogs' => 'Блоги',
|
||||
'readers_declension' => 'читатель;читателя;читателей',
|
||||
|
@ -381,7 +381,7 @@ return array(
|
|||
/**
|
||||
* Личные сообщения
|
||||
*/
|
||||
'talk' => array(
|
||||
'talk' => array(
|
||||
'title' => 'Сообщения',
|
||||
'participants' => '%%count%% участник;%%count%% участника;%%count%% участников',
|
||||
'new_messages' => 'У вас есть новые сообщения',
|
||||
|
@ -501,7 +501,7 @@ return array(
|
|||
/**
|
||||
* Опросы
|
||||
*/
|
||||
'poll' => array(
|
||||
'poll' => array(
|
||||
'polls' => 'Опросы',
|
||||
'answer' => 'Вопрос',
|
||||
'vote' => 'Голосовать',
|
||||
|
@ -791,7 +791,7 @@ return array(
|
|||
/**
|
||||
* Стена
|
||||
*/
|
||||
'wall' => array(
|
||||
'wall' => array(
|
||||
'title' => 'Стена',
|
||||
// Форма
|
||||
'form' => array(
|
||||
|
@ -816,7 +816,7 @@ return array(
|
|||
/**
|
||||
* Авторизация
|
||||
*/
|
||||
'auth' => array(
|
||||
'auth' => array(
|
||||
'authorization' => 'Авторизация',
|
||||
'logout' => 'Выйти',
|
||||
// Вход
|
||||
|
@ -1018,7 +1018,7 @@ return array(
|
|||
/**
|
||||
* Лента
|
||||
*/
|
||||
'feed' => array(
|
||||
'feed' => array(
|
||||
'title' => 'Лента',
|
||||
// Блоги
|
||||
'blogs' => array(
|
||||
|
@ -1035,7 +1035,7 @@ return array(
|
|||
/**
|
||||
* Топик
|
||||
*/
|
||||
'topic' => array(
|
||||
'topic' => array(
|
||||
'topics' => 'Топики',
|
||||
'topic_plural' => 'топик;топика;топиков',
|
||||
'drafts' => 'Черновики',
|
||||
|
@ -1122,7 +1122,7 @@ return array(
|
|||
* Пользователь
|
||||
* !user
|
||||
*/
|
||||
'user' => array(
|
||||
'user' => array(
|
||||
'user' => 'Пользователь',
|
||||
'users' => 'Пользователи',
|
||||
'rating' => '___vote.rating___',
|
||||
|
@ -1411,7 +1411,7 @@ return array(
|
|||
/**
|
||||
* Поля
|
||||
*/
|
||||
'field' => array(
|
||||
'field' => array(
|
||||
'email' => array(
|
||||
'label' => 'E-mail',
|
||||
'notices' => array(
|
||||
|
@ -1487,25 +1487,30 @@ return array(
|
|||
/**
|
||||
* Админка
|
||||
*/
|
||||
'admin' => array(
|
||||
'title' => 'Админка',
|
||||
'items' => array(
|
||||
'admin' => array(
|
||||
'title' => 'Админка',
|
||||
'items' => array(
|
||||
'plugins' => '___admin.plugins.title___',
|
||||
),
|
||||
'install_plugin_admin' => 'Установить расширенную админ-панель',
|
||||
|
||||
// Страница администрирования плагинов
|
||||
'plugins' => array(
|
||||
'title' => 'Управление плагинами',
|
||||
'plugin_name' => 'Название',
|
||||
'plugin_author' => 'Автор',
|
||||
'plugin_version' => 'Версия',
|
||||
'plugin_activate' => 'Активировать',
|
||||
'plugin_deactivate' => 'Деактивировать',
|
||||
'plugin_settings' => 'Настройки',
|
||||
'plugin_delete' => '___common.remove___',
|
||||
'plugin_apply_update' => 'Применить обновление',
|
||||
'plugins' => array(
|
||||
'title' => 'Управление плагинами',
|
||||
|
||||
'plugin' => array(
|
||||
'author' => 'Автор',
|
||||
'version' => 'Версия',
|
||||
'url' => 'Сайт',
|
||||
'activate' => 'Активировать',
|
||||
'deactivate' => 'Деактивировать',
|
||||
'settings' => 'Настройки',
|
||||
'remove' => '___common.remove___',
|
||||
'apply_update' => 'Применить обновление',
|
||||
),
|
||||
|
||||
// Сообщения
|
||||
'notices' => array(
|
||||
'notices' => array(
|
||||
'unknown_action' => 'Указано неизвестное действие',
|
||||
'action_ok' => 'Успешно выполнено',
|
||||
'activation_overlap' => 'Конфликт с активированным плагином. Ресурс %%resource%% переопределен на %%delegate%% плагином %%plugin%%.',
|
||||
|
@ -1569,7 +1574,7 @@ return array(
|
|||
/**
|
||||
* Загрузка изображений
|
||||
*/
|
||||
'media' => array(
|
||||
'media' => array(
|
||||
'title' => 'Загрузка медиа-файлов',
|
||||
'nav' => array(
|
||||
'insert' => 'Вставить',
|
||||
|
@ -1626,7 +1631,7 @@ return array(
|
|||
/**
|
||||
* Дата
|
||||
*/
|
||||
'date' => array(
|
||||
'date' => array(
|
||||
'day' => 'день',
|
||||
'month' => 'месяц',
|
||||
'year' => 'год',
|
||||
|
@ -1699,7 +1704,7 @@ return array(
|
|||
/**
|
||||
* Теги
|
||||
*/
|
||||
'tags' => array(
|
||||
'tags' => array(
|
||||
'tags' => 'Теги',
|
||||
'tag' => 'Тег',
|
||||
'search' => array(
|
||||
|
@ -1779,7 +1784,7 @@ return array(
|
|||
/**
|
||||
* Управление правами (RBAC)
|
||||
*/
|
||||
'rbac' => array(
|
||||
'rbac' => array(
|
||||
'permission' => array(
|
||||
'create_blog' => array(
|
||||
'title' => 'Создание блога',
|
||||
|
@ -1834,7 +1839,7 @@ return array(
|
|||
/**
|
||||
* Системные сообщения
|
||||
*/
|
||||
'error' => 'Ошибка',
|
||||
'error' => 'Ошибка',
|
||||
'attention' => 'Внимание',
|
||||
'system_error' => 'Системная ошибка, повторите позже',
|
||||
'system_error_event_args' => 'Некорректное число аргументов при добавлении евента',
|
||||
|
|
|
@ -22,5 +22,5 @@
|
|||
{/block}
|
||||
|
||||
{block 'layout_content'}
|
||||
{include 'components/blog/add.tpl'}
|
||||
{include 'components/blog/add.tpl' blog=$oBlogEdit}
|
||||
{/block}
|
|
@ -20,5 +20,5 @@
|
|||
{/block}
|
||||
|
||||
{block 'layout_content'}
|
||||
{include 'components/blog/admin.tpl'}
|
||||
{include 'components/blog/admin.tpl' users=$aBlogUsers pagination=$aPaging}
|
||||
{/block}
|
|
@ -10,9 +10,6 @@
|
|||
* @param integer $iCountBlogAdministrators Кол-во администраторов
|
||||
* @param boolean $bPrivateBlog Закрытый блог или нет
|
||||
*
|
||||
* @styles css/blog.css
|
||||
* @scripts <framework>/js/livestreet/blog.js
|
||||
*
|
||||
* TODO: Fix alerts
|
||||
*}
|
||||
|
||||
|
|
|
@ -27,6 +27,6 @@
|
|||
]}
|
||||
|
||||
<div class="js-search-ajax-container" data-type="blogs">
|
||||
{include 'components/blog/blog-list.tpl' aBlogs=$aBlogs bUseMore=true}
|
||||
{include 'components/blog/blog-list.tpl' blogs=$aBlogs useMore=true pagination=$aPaging}
|
||||
</div>
|
||||
{/block}
|
|
@ -12,7 +12,7 @@
|
|||
{include 'navs/nav.user.favourite.tpl'}
|
||||
|
||||
{* Блок с тегами избранного *}
|
||||
{if $oUserCurrent and $oUserCurrent->getId() == $oUserProfile->getId()}
|
||||
{if $oUserCurrent && $oUserCurrent->getId() == $oUserProfile->getId()}
|
||||
{insert name="block" block=tagsFavouriteTopic params={$aBlockParams.user=$oUserProfile}}
|
||||
{/if}
|
||||
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
# Компонент accordion
|
|
@ -1,11 +1,16 @@
|
|||
{**
|
||||
* Accordion
|
||||
*
|
||||
* @param array $items
|
||||
* @param string $mods
|
||||
* @param string $classes
|
||||
* @param string $attributes
|
||||
*}
|
||||
|
||||
{$component = 'accordion'}
|
||||
|
||||
<div class="{$component} {mod name=$component mods=$smarty.local.mods} {$smarty.local.classes}" {$smarty.local.attributes}>
|
||||
{foreach $items as $item}
|
||||
{foreach $smarty.local.items as $item}
|
||||
<h3>{$item[ 'title' ]}</h3>
|
||||
<div>{$item[ 'content' ]}</div>
|
||||
{/foreach}
|
||||
|
|
|
@ -1,3 +1,11 @@
|
|||
/**
|
||||
* Accordion
|
||||
*
|
||||
* @license GNU General Public License, version 2
|
||||
* @copyright 2013 OOO "ЛС-СОФТ" {@link http://livestreetcms.com}
|
||||
* @author Denis Shakhov <denis.shakhov@gmail.com>
|
||||
*/
|
||||
|
||||
.accordion {
|
||||
margin-bottom: 15px;
|
||||
}
|
|
@ -2,8 +2,9 @@
|
|||
* Экшнбар / Контрол выбора объектов
|
||||
*
|
||||
* @param string $target
|
||||
* @param string $items
|
||||
*
|
||||
* @extends {actionbar}/actionbar-item.tpl
|
||||
* @extends {actionbar}/actionbar-item
|
||||
*}
|
||||
|
||||
{extends './actionbar-item.tpl'}
|
||||
|
|
|
@ -1,18 +1,25 @@
|
|||
{**
|
||||
* Кнопка экшнбара
|
||||
*
|
||||
* @param array $item Массив с опциями кнопки
|
||||
* @param string $icon
|
||||
* @param string $text
|
||||
* @param string $url
|
||||
* @param string $show
|
||||
* @param string $classes
|
||||
* @param string $attributes
|
||||
*}
|
||||
|
||||
{$item = $smarty.local.item}
|
||||
{$component = 'actionbar-item'}
|
||||
|
||||
<li class="actionbar-item">
|
||||
{block 'actionbar_item'}
|
||||
{include 'components/button/button.tpl'
|
||||
url = $item['url']
|
||||
classes = "actionbar-item-link {$item['classes']}"
|
||||
text = $item['text']
|
||||
icon = $item['icon']
|
||||
attributes = $item['attributes']}
|
||||
{/block}
|
||||
</li>
|
||||
{if $smarty.local.show|default:true}
|
||||
<li class="{$component}">
|
||||
{block 'actionbar_item'}
|
||||
{include 'components/button/button.tpl'
|
||||
url = $smarty.local.url
|
||||
classes = "{$component}-link {$smarty.local.classes}"
|
||||
text = $smarty.local.text
|
||||
icon = $smarty.local.icon
|
||||
attributes = $smarty.local.attributes}
|
||||
{/block}
|
||||
</li>
|
||||
{/if}
|
|
@ -1,21 +1,27 @@
|
|||
{**
|
||||
* Экшнбар
|
||||
*
|
||||
* @param array $items Массив с кнопками
|
||||
* @param array $items Массив с кнопками
|
||||
* @param string $mods
|
||||
* @param string $classes
|
||||
* @param string $attributes
|
||||
*}
|
||||
|
||||
{* Название компонента *}
|
||||
{$component = 'actionbar'}
|
||||
|
||||
{if $smarty.local.items}
|
||||
<ul class="{$component} clearfix {mod name=$component mods=$smarty.local.mods} {$smarty.local.classes}" {$smarty.local.attributes}>
|
||||
{foreach $smarty.local.items as $item}
|
||||
{if $item['html']}
|
||||
{$item['html']}
|
||||
{if $item[ 'html' ]}
|
||||
{$item[ 'html' ]}
|
||||
{else}
|
||||
{if $item['show']|default:true}
|
||||
{include './actionbar-item.tpl' item=$item}
|
||||
{/if}
|
||||
{include './actionbar-item.tpl'
|
||||
url = $item[ 'url' ]
|
||||
classes = $item[ 'classes' ]
|
||||
text = $item[ 'text' ]
|
||||
icon = $item[ 'icon' ]
|
||||
show = $item[ 'show' ]
|
||||
attributes = $item[ 'attributes' ]}
|
||||
{/if}
|
||||
{/foreach}
|
||||
</ul>
|
||||
|
|
|
@ -1,9 +1,6 @@
|
|||
/**
|
||||
* Экшнбар
|
||||
*
|
||||
* @template components/actionbar/*.tpl
|
||||
* @scripts <common>/js/actionbar.js
|
||||
*
|
||||
* @license GNU General Public License, version 2
|
||||
* @copyright 2013 OOO "ЛС-СОФТ" {@link http://livestreetcms.com}
|
||||
* @author Denis Shakhov <denis.shakhov@gmail.com>
|
||||
|
|
|
@ -4,6 +4,10 @@
|
|||
* @param array $events
|
||||
* @param integer $targetId
|
||||
* @param integer $count
|
||||
*
|
||||
* @param string $mods
|
||||
* @param string $classes
|
||||
* @param string $attributes
|
||||
*}
|
||||
|
||||
{$component = 'activity'}
|
||||
|
|
|
@ -1,10 +1,6 @@
|
|||
/**
|
||||
* Активность
|
||||
*
|
||||
* @version 2.0.dev
|
||||
* @template actions/ActionStream/*.tpl
|
||||
* @scripts <frontend>/common/js/stream.js
|
||||
*
|
||||
* @license GNU General Public License, version 2
|
||||
* @copyright 2013 OOO "ЛС-СОФТ" {@link http://livestreetcms.com}
|
||||
* @author Denis Shakhov <denis.shakhov@gmail.com>
|
||||
|
@ -14,14 +10,42 @@
|
|||
/**
|
||||
* Список событий
|
||||
*/
|
||||
.activity-event-list { margin: 0 0 20px; }
|
||||
.activity-date { font-family: 'Open Sans', sans-serif; font-size: 20px; margin-top: 45px; padding-bottom: 10px; border-bottom: 1px solid #eee; }
|
||||
|
||||
.activity-event-list {
|
||||
margin: 0 0 20px;
|
||||
}
|
||||
.activity-date {
|
||||
font-family: 'Open Sans', sans-serif;
|
||||
font-size: 20px;
|
||||
margin-top: 45px;
|
||||
padding-bottom: 10px;
|
||||
border-bottom: 1px solid #eee;
|
||||
}
|
||||
|
||||
/**
|
||||
* Событие
|
||||
*/
|
||||
.activity-event { margin-bottom: 5px; min-height: 48px; background: #fafafa; padding: 15px 15px 15px 75px; position: relative; }
|
||||
.activity-event-avatar { position: absolute; top: 15px; left: 15px; }
|
||||
.activity-event-date { display: block; color: #999; margin-bottom: 4px; }
|
||||
.activity-event-text { padding: 10px 15px; background: #fff; border: 1px solid #eee; border-bottom-color: #ddd; margin-top: 10px; font-size: 13px; }
|
||||
.activity-event {
|
||||
margin-bottom: 5px;
|
||||
min-height: 48px;
|
||||
background: #fafafa;
|
||||
padding: 15px 15px 15px 75px;
|
||||
position: relative;
|
||||
}
|
||||
.activity-event-avatar {
|
||||
position: absolute;
|
||||
top: 15px;
|
||||
left: 15px;
|
||||
}
|
||||
.activity-event-date {
|
||||
display: block;
|
||||
color: #999;
|
||||
margin-bottom: 4px;
|
||||
}
|
||||
.activity-event-text {
|
||||
padding: 10px 15px;
|
||||
background: #fff;
|
||||
border: 1px solid #eee;
|
||||
border-bottom-color: #ddd;
|
||||
margin-top: 10px;
|
||||
font-size: 13px;
|
||||
}
|
|
@ -1,5 +1,5 @@
|
|||
/**
|
||||
* Activity Item List
|
||||
* Последняя активность
|
||||
*
|
||||
* @license GNU General Public License, version 2
|
||||
* @copyright 2013 OOO "ЛС-СОФТ" {@link http://livestreetcms.com}
|
||||
|
@ -8,10 +8,34 @@
|
|||
* TODO: Component item
|
||||
*/
|
||||
|
||||
.block-item-list li { min-height: 51px; padding: 17px 15px 20px 80px; border-top: 1px solid #eee; position: relative; zoom: 1; background: #fff; }
|
||||
.block-item-list li:first-child { border: none; }
|
||||
.block-item-list li p { padding-top: 2px; font-size: 11px; }
|
||||
.block-item-list li a { text-decoration: none; }
|
||||
.block-item-list li .avatar { position: absolute; top: 20px; left: 20px; margin-right: 10px; }
|
||||
.block-item-list li .author { font-weight: bold; color: #333; }
|
||||
.block-item-list li .blog-name { font-weight: bold; }
|
||||
.block-item-list li {
|
||||
min-height: 51px;
|
||||
padding: 17px 15px 20px 80px;
|
||||
border-top: 1px solid #eee;
|
||||
position: relative;
|
||||
zoom: 1;
|
||||
background: #fff;
|
||||
}
|
||||
.block-item-list li:first-child {
|
||||
border: none;
|
||||
}
|
||||
.block-item-list li p {
|
||||
padding-top: 2px;
|
||||
font-size: 11px;
|
||||
}
|
||||
.block-item-list li a {
|
||||
text-decoration: none;
|
||||
}
|
||||
.block-item-list li .avatar {
|
||||
position: absolute;
|
||||
top: 20px;
|
||||
left: 20px;
|
||||
margin-right: 10px;
|
||||
}
|
||||
.block-item-list li .author {
|
||||
font-weight: bold;
|
||||
color: #333;
|
||||
}
|
||||
.block-item-list li .blog-name {
|
||||
font-weight: bold;
|
||||
}
|
|
@ -46,39 +46,39 @@
|
|||
{* Текст события *}
|
||||
{if $type == 'add_topic'}
|
||||
{* Добавлен топик *}
|
||||
{lang name="activity.events.{$type}_{$gender}" topic="<a href=\"{$target->getUrl()}\">{$target->getTitle()|escape}</a>"}
|
||||
{lang "activity.events.{$type}_{$gender}" topic="<a href=\"{$target->getUrl()}\">{$target->getTitle()|escape}</a>"}
|
||||
{elseif $type == 'add_comment'}
|
||||
{* Добавлен комментарий *}
|
||||
{lang name="activity.events.{$type}_{$gender}" topic="<a href=\"{$target->getTarget()->getUrl()}#comment{$target->getId()}\">{$target->getTarget()->getTitle()|escape}</a>"}
|
||||
{lang "activity.events.{$type}_{$gender}" topic="<a href=\"{$target->getTarget()->getUrl()}#comment{$target->getId()}\">{$target->getTarget()->getTitle()|escape}</a>"}
|
||||
|
||||
{activity_event_text text=$target->getText()}
|
||||
{elseif $type == 'add_blog'}
|
||||
{* Создан блог *}
|
||||
{lang name="activity.events.{$type}_{$gender}" blog="<a href=\"{$target->getUrlFull()}\">{$target->getTitle()|escape}</a>"}
|
||||
{lang "activity.events.{$type}_{$gender}" blog="<a href=\"{$target->getUrlFull()}\">{$target->getTitle()|escape}</a>"}
|
||||
{elseif $type == 'vote_blog'}
|
||||
{* Проголосовали за блог *}
|
||||
{lang name="activity.events.{$type}_{$gender}" blog="<a href=\"{$target->getUrlFull()}\">{$target->getTitle()|escape}</a>"}
|
||||
{lang "activity.events.{$type}_{$gender}" blog="<a href=\"{$target->getUrlFull()}\">{$target->getTitle()|escape}</a>"}
|
||||
{elseif $type == 'vote_topic'}
|
||||
{* Проголосовали за топик *}
|
||||
{lang name="activity.events.{$type}_{$gender}" topic="<a href=\"{$target->getUrl()}\">{$target->getTitle()|escape}</a>"}
|
||||
{lang "activity.events.{$type}_{$gender}" topic="<a href=\"{$target->getUrl()}\">{$target->getTitle()|escape}</a>"}
|
||||
{elseif $type == 'vote_comment_topic'}
|
||||
{* Проголосовали за комментарий *}
|
||||
{lang name="activity.events.{$type}_{$gender}" topic="<a href=\"{$target->getTarget()->getUrl()}#comment{$target->getId()}\">{$target->getTarget()->getTitle()|escape}</a>"}
|
||||
{lang "activity.events.{$type}_{$gender}" topic="<a href=\"{$target->getTarget()->getUrl()}#comment{$target->getId()}\">{$target->getTarget()->getTitle()|escape}</a>"}
|
||||
{elseif $type == 'vote_user'}
|
||||
{* Проголосовали за пользователя *}
|
||||
{lang name="activity.events.{$type}_{$gender}" user="<a href=\"{$target->getUserWebPath()}\">{$target->getDisplayName()}</a>"}
|
||||
{lang "activity.events.{$type}_{$gender}" user="<a href=\"{$target->getUserWebPath()}\">{$target->getDisplayName()}</a>"}
|
||||
{elseif $type == 'join_blog'}
|
||||
{* Вступили в блог *}
|
||||
{lang name="activity.events.{$type}_{$gender}" blog="<a href=\"{$target->getUrlFull()}\">{$target->getTitle()|escape}</a>"}
|
||||
{lang "activity.events.{$type}_{$gender}" blog="<a href=\"{$target->getUrlFull()}\">{$target->getTitle()|escape}</a>"}
|
||||
{elseif $type == 'add_friend'}
|
||||
{* Добавили в друзья *}
|
||||
{lang name="activity.events.{$type}_{$gender}" user="<a href=\"{$target->getUserWebPath()}\">{$target->getDisplayName()}</a>"}
|
||||
{lang "activity.events.{$type}_{$gender}" user="<a href=\"{$target->getUserWebPath()}\">{$target->getDisplayName()}</a>"}
|
||||
{elseif $type == 'add_wall'}
|
||||
{* Написали на стене *}
|
||||
{if $target->getWallUser()->getId() == $user->getId()}
|
||||
{lang name="activity.events.{$type}_self_{$gender}" url=$target->getUrlWall()}
|
||||
{lang "activity.events.{$type}_self_{$gender}" url=$target->getUrlWall()}
|
||||
{else}
|
||||
{lang name="activity.events.{$type}_{$gender}" url=$target->getUrlWall() user=$target->getWallUser()->getDisplayName()}
|
||||
{lang "activity.events.{$type}_{$gender}" url=$target->getUrlWall() user=$target->getWallUser()->getDisplayName()}
|
||||
{/if}
|
||||
|
||||
{activity_event_text text=$target->getText()}
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
# Компонент admin
|
|
@ -11,13 +11,22 @@
|
|||
*
|
||||
* @template plugins.tpl
|
||||
*/
|
||||
.table.table-plugins .cell-checkbox {
|
||||
width: 20px;
|
||||
padding: 12px 0 10px 10px;
|
||||
.admin-plugins h3 {
|
||||
font-weight: bold;
|
||||
font-size: 17px;
|
||||
line-height: 20px;
|
||||
margin-bottom: 7px;
|
||||
}
|
||||
.table.table-plugins h3 {
|
||||
font-weight: bold;
|
||||
font-size: 17px;
|
||||
line-height: 20px;
|
||||
margin-bottom: 5px;
|
||||
.admin-plugins p {
|
||||
margin-bottom: 15px;
|
||||
}
|
||||
.admin-plugins td {
|
||||
vertical-align: top;
|
||||
}
|
||||
.admin-plugins-actions li {
|
||||
margin-bottom: 5px;
|
||||
text-align: right;
|
||||
}
|
||||
.admin-plugins-actions li:last-child {
|
||||
margin-bottom: 0;
|
||||
}
|
|
@ -1,12 +1,18 @@
|
|||
{**
|
||||
* Админка
|
||||
*}
|
||||
|
||||
<ul>
|
||||
{if $bAvailableAdminPlugin}
|
||||
<li>
|
||||
<a href="{router page='admin/plugins'}?plugin=admin&action=activate&security_ls_key={$LIVESTREET_SECURITY_KEY}">
|
||||
<strong>{lang name='admin.install_plugin_admin'}</strong>
|
||||
<strong>{lang 'admin.install_plugin_admin'}</strong>
|
||||
</a>
|
||||
</li>
|
||||
{/if}
|
||||
<li><a href="{router page="admin"}plugins/">{lang name='admin.items.plugins'}</a></li>
|
||||
|
||||
<li><a href="{router page="admin"}plugins/">{lang 'admin.items.plugins'}</a></li>
|
||||
|
||||
{hook run='admin_action_item'}
|
||||
</ul>
|
||||
|
||||
|
|
|
@ -1,45 +1,68 @@
|
|||
<table class="table table-plugins">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>{$aLang.admin.plugins.plugin_name}</th>
|
||||
<th>{$aLang.admin.plugins.plugin_version}</th>
|
||||
<th>{$aLang.admin.plugins.plugin_author}</th>
|
||||
<th>{$aLang.admin.plugins.plugin_settings}</th>
|
||||
<th></th>
|
||||
</tr>
|
||||
</thead>
|
||||
{**
|
||||
* Список плагинов
|
||||
*
|
||||
* @param array $plugins Список плагинов
|
||||
*}
|
||||
|
||||
<table class="table admin-plugins">
|
||||
<tbody>
|
||||
{foreach $smarty.local.plugins as $plugin}
|
||||
<tr {if $plugin.is_active}class="active"{/if}>
|
||||
{* Название и описание плагина *}
|
||||
<td>
|
||||
<h3>{$plugin.property->name->data}</h3>
|
||||
{$plugin.property->description->data}
|
||||
</td>
|
||||
<td>
|
||||
{$plugin.property->version|escape}
|
||||
</td>
|
||||
<td>
|
||||
{$plugin.property->author->data}<br />
|
||||
{$plugin.property->homepage}
|
||||
</td>
|
||||
<td>
|
||||
{if $plugin.property->settings != "" && $plugin.is_active}
|
||||
<a href="{$plugin.property->settings}">{$aLang.admin.plugins.plugin_settings}</a>
|
||||
{/if}
|
||||
</td>
|
||||
<td align="center">
|
||||
{if $plugin.is_active}
|
||||
<a href="{router page='admin'}plugins/?plugin={$plugin.code}&action=deactivate&security_ls_key={$LIVESTREET_SECURITY_KEY}" class="button">{$aLang.admin.plugins.plugin_deactivate}</a>
|
||||
{else}
|
||||
<a href="{router page='admin'}plugins/?plugin={$plugin.code}&action=activate&security_ls_key={$LIVESTREET_SECURITY_KEY}" class="button button-primary">{$aLang.admin.plugins.plugin_activate}</a>
|
||||
{/if}
|
||||
<p>{$plugin.property->description->data}</p>
|
||||
|
||||
{if $plugin.apply_update and $plugin.is_active}
|
||||
<a href="{router page='admin'}plugins/?plugin={$plugin.code}&action=apply_update&security_ls_key={$LIVESTREET_SECURITY_KEY}" class="button">{lang name='admin.plugins.plugin_apply_update'}</a>
|
||||
{/if}
|
||||
{include 'components/info-list/info-list.tpl' list=[
|
||||
[ 'label' => {lang 'admin.plugins.plugin.version'}, 'content' => $plugin.property->version|escape ],
|
||||
[ 'label' => {lang 'admin.plugins.plugin.author'}, 'content' => $plugin.property->author->data ],
|
||||
[ 'label' => {lang 'admin.plugins.plugin.url'}, 'content' => $plugin.property->homepage ]
|
||||
]}
|
||||
</td>
|
||||
|
||||
<a href="{router page='admin'}plugins/?plugin={$plugin.code}&action=remove&security_ls_key={$LIVESTREET_SECURITY_KEY}" class="button" onclick="return confirm('{$aLang.common.remove_confirm}');">{lang name='admin.plugins.plugin_delete'}</a>
|
||||
{* Действия *}
|
||||
<td>
|
||||
<ul class="admin-plugins-actions">
|
||||
{* Активировать/деактивировать *}
|
||||
<li>
|
||||
{if $plugin.is_active}
|
||||
{include 'components/button/button.tpl'
|
||||
url = "{router page='admin'}plugins/?plugin={$plugin.code}&action=deactivate&security_ls_key={$LIVESTREET_SECURITY_KEY}"
|
||||
text = {lang 'admin.plugins.plugin.deactivate'}}
|
||||
{else}
|
||||
{include 'components/button/button.tpl'
|
||||
url = "{router page='admin'}plugins/?plugin={$plugin.code}&action=deactivate&security_ls_key={$LIVESTREET_SECURITY_KEY}"
|
||||
mods = 'primary'
|
||||
text = {lang 'admin.plugins.plugin.activate'}}
|
||||
{/if}
|
||||
</li>
|
||||
|
||||
{* Применить обновление *}
|
||||
{if $plugin.apply_update && $plugin.is_active}
|
||||
<li>
|
||||
{include 'components/button/button.tpl'
|
||||
url = "{router page='admin'}plugins/?plugin={$plugin.code}&action=apply_update&security_ls_key={$LIVESTREET_SECURITY_KEY}"
|
||||
text = {lang 'admin.plugins.plugin.apply_update'}}
|
||||
</li>
|
||||
{/if}
|
||||
|
||||
{* Ссылка на страницу настроек *}
|
||||
{if $plugin.property->settings != "" && $plugin.is_active}
|
||||
<li>
|
||||
{include 'components/button/button.tpl'
|
||||
url = $plugin.property->settings
|
||||
text = {lang 'admin.plugins.plugin.settings'}}
|
||||
</li>
|
||||
{/if}
|
||||
|
||||
{* Удалить *}
|
||||
<li>
|
||||
{include 'components/button/button.tpl'
|
||||
url = "{router page='admin'}plugins/?plugin={$plugin.code}&action=remove&security_ls_key={$LIVESTREET_SECURITY_KEY}"
|
||||
attributes = "onclick=\"return confirm('{lang 'common.remove_confirm'}');\""
|
||||
text = {lang 'admin.plugins.plugin.remove'}}
|
||||
</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
{/foreach}
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
|
||||
{block 'toolbar_item_options' append}
|
||||
{$_mods = 'admin'}
|
||||
{$_bShow = $oUserCurrent and $oUserCurrent->isAdministrator()}
|
||||
{$_bShow = $oUserCurrent && $oUserCurrent->isAdministrator()}
|
||||
{/block}
|
||||
|
||||
{block 'toolbar_item'}
|
||||
|
|
|
@ -1,20 +1,23 @@
|
|||
{**
|
||||
* Алфавитный указатель
|
||||
*
|
||||
* @param array $letters
|
||||
* @param array $letters
|
||||
* @param array $type
|
||||
*
|
||||
* @styles assets/css/common.css
|
||||
* @param string $mods
|
||||
* @param string $classes
|
||||
* @param string $attributes
|
||||
*}
|
||||
|
||||
{* Название компонента *}
|
||||
{$component = 'alphanumeric'}
|
||||
|
||||
<ul class="{$component} {mod name=$component mods=$mods} js-search-alphabet {$smarty.local.classes}" {if $smarty.local.type}data-type="{$smarty.local.type}"{/if}>
|
||||
<ul class="{$component} {mod name=$component mods=$smarty.local.mods} js-search-alphabet {$smarty.local.classes}" {if $smarty.local.type}data-type="{$smarty.local.type}"{/if}>
|
||||
<li class="{$component}-item active js-search-alphabet-item" data-letter="">
|
||||
<a href="#">{lang 'alphanumeric.all'}</a>
|
||||
</li>
|
||||
|
||||
{foreach $letters as $letter}
|
||||
{foreach $smarty.local.letters as $letter}
|
||||
<li class="{$component}-item js-search-alphabet-item" data-letter="{$letter}">
|
||||
<a href="#">{$letter}</a>
|
||||
</li>
|
||||
|
|
|
@ -1,8 +1,26 @@
|
|||
/**
|
||||
* Алфавитный указатель
|
||||
*/
|
||||
.alphanumeric { overflow: hidden; background: #f7f7f7; margin-bottom: 20px; padding: 15px; }
|
||||
.alphanumeric-item { float: left; margin-right: 1px; }
|
||||
.alphanumeric-item a { float: left; padding: 5px 10px; color: #333; }
|
||||
.alphanumeric-item.active { background: #333; border-radius: 3px; }
|
||||
.alphanumeric-item.active a { color: #fff; }
|
||||
|
||||
.alphanumeric {
|
||||
overflow: hidden;
|
||||
background: #f7f7f7;
|
||||
margin-bottom: 20px;
|
||||
padding: 15px;
|
||||
}
|
||||
.alphanumeric-item {
|
||||
float: left;
|
||||
margin-right: 1px;
|
||||
}
|
||||
.alphanumeric-item a {
|
||||
float: left;
|
||||
padding: 5px 10px;
|
||||
color: #333;
|
||||
}
|
||||
.alphanumeric-item.active {
|
||||
background: #333;
|
||||
border-radius: 3px;
|
||||
}
|
||||
.alphanumeric-item.active a {
|
||||
color: #fff;
|
||||
}
|
|
@ -0,0 +1 @@
|
|||
# Компонент article
|
|
@ -1,8 +1,13 @@
|
|||
{**
|
||||
* Базовый шаблон топика
|
||||
*
|
||||
* @styles assets/css/topic.css
|
||||
* @scripts <framework>/js/livestreet/topic.js
|
||||
* @param boolean $isPreview
|
||||
* @param boolean $isList
|
||||
* @param string $type
|
||||
*
|
||||
* @param string $mods
|
||||
* @param string $classes
|
||||
* @param string $attributes
|
||||
*}
|
||||
|
||||
{* Название компонента *}
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
# Компонент auth
|
|
@ -3,10 +3,10 @@
|
|||
*}
|
||||
|
||||
<form action="{router page='registration'}invite/" method="post">
|
||||
{include 'components/field/field.text.tpl'
|
||||
name = 'invite_code'
|
||||
rules = [ 'required' => true, 'type' => 'alphanum' ]
|
||||
label = $aLang.auth.invite.form.fields.code.label}
|
||||
{include 'components/field/field.text.tpl'
|
||||
name = 'invite_code'
|
||||
rules = [ 'required' => true, 'type' => 'alphanum' ]
|
||||
label = $aLang.auth.invite.form.fields.code.label}
|
||||
|
||||
{include 'components/button/button.tpl' name='submit_invite' mods='primary' text=$aLang.auth.invite.form.fields.submit.text}
|
||||
{include 'components/button/button.tpl' name='submit_invite' mods='primary' text=$aLang.auth.invite.form.fields.submit.text}
|
||||
</form>
|
|
@ -1,5 +1,7 @@
|
|||
{**
|
||||
* Форма входа
|
||||
*
|
||||
* @param string $redirectUrl
|
||||
*}
|
||||
|
||||
{$redirectUrl = $smarty.local.redirectUrl|default:$PATH_WEB_CURRENT}
|
||||
|
|
|
@ -3,8 +3,8 @@
|
|||
*}
|
||||
|
||||
<form action="{router page='registration'}reactivation/" method="post" class="js-form-reactivation">
|
||||
{* E-mail *}
|
||||
{* E-mail *}
|
||||
{include 'components/field/field.email.tpl' label=$aLang.auth.reactivation.form.fields.mail.label}
|
||||
|
||||
{include 'components/button/button.tpl' name='submit_reactivation' mods='primary' text=$aLang.auth.reactivation.form.fields.submit.text}
|
||||
{include 'components/button/button.tpl' name='submit_reactivation' mods='primary' text=$aLang.auth.reactivation.form.fields.submit.text}
|
||||
</form>
|
|
@ -1,7 +1,7 @@
|
|||
{**
|
||||
* Форма регистрации
|
||||
*
|
||||
* isModal Если true, то форма выводится в модальном окне
|
||||
* @param string $redirectUrl
|
||||
*}
|
||||
|
||||
{$redirectUrl = $smarty.local.redirectUrl|default:$PATH_WEB_CURRENT}
|
||||
|
@ -13,33 +13,33 @@
|
|||
|
||||
{* Логин *}
|
||||
{include 'components/field/field.text.tpl'
|
||||
name = 'login'
|
||||
rules = [ 'required' => true, 'rangelength' => '[2,20]', 'remote' => "{router page='registration'}ajax-validate-fields", 'remote-method' => 'POST' ]
|
||||
label = $aLang.auth.labels.login}
|
||||
name = 'login'
|
||||
rules = [ 'required' => true, 'rangelength' => '[2,20]', 'remote' => "{router page='registration'}ajax-validate-fields", 'remote-method' => 'POST' ]
|
||||
label = $aLang.auth.labels.login}
|
||||
|
||||
{* E-mail *}
|
||||
{include 'components/field/field.email.tpl' rules=[ 'remote' => "{router page='registration'}ajax-validate-fields", 'remote-method' => 'POST' ]}
|
||||
|
||||
{* Пароль *}
|
||||
{include 'components/field/field.text.tpl'
|
||||
name = 'password'
|
||||
type = 'password'
|
||||
rules = [ 'required' => true, 'rangelength' => '[5,20]' ]
|
||||
label = $aLang.auth.labels.password
|
||||
inputClasses = 'js-input-password-reg'}
|
||||
name = 'password'
|
||||
type = 'password'
|
||||
rules = [ 'required' => true, 'rangelength' => '[5,20]' ]
|
||||
label = $aLang.auth.labels.password
|
||||
inputClasses = 'js-input-password-reg'}
|
||||
|
||||
{* Повторите пароль *}
|
||||
{include 'components/field/field.text.tpl'
|
||||
name = 'password_confirm'
|
||||
type = 'password'
|
||||
rules = [ 'required' => true, 'rangelength' => '[5,20]', 'equalto' => '.js-input-password-reg' ]
|
||||
label = $aLang.auth.registration.form.fields.password_confirm.label}
|
||||
name = 'password_confirm'
|
||||
type = 'password'
|
||||
rules = [ 'required' => true, 'rangelength' => '[5,20]', 'equalto' => '.js-input-password-reg' ]
|
||||
label = $aLang.auth.registration.form.fields.password_confirm.label}
|
||||
|
||||
{* Каптча *}
|
||||
{include 'components/field/field.captcha.tpl'
|
||||
name = 'captcha'
|
||||
captchaName = 'user_signup'
|
||||
label = $aLang.auth.labels.captcha}
|
||||
name = 'captcha'
|
||||
captchaName = 'user_signup'
|
||||
label = $aLang.auth.labels.captcha}
|
||||
|
||||
{hook run='form_registration_end'}
|
||||
|
||||
|
|
|
@ -3,8 +3,8 @@
|
|||
*}
|
||||
|
||||
<form action="{router page='login'}reminder/" method="post" class="js-auth-reset-form">
|
||||
{* E-mail *}
|
||||
{* E-mail *}
|
||||
{include 'components/field/field.email.tpl' label=$aLang.auth.reset.form.fields.mail.label}
|
||||
|
||||
{include 'components/button/button.tpl' name='submit_reset' mods='primary' text=$aLang.auth.reset.form.fields.submit.text}
|
||||
{include 'components/button/button.tpl' name='submit_reset' mods='primary' text=$aLang.auth.reset.form.fields.submit.text}
|
||||
</form>
|
|
@ -1,7 +1,5 @@
|
|||
{**
|
||||
* Модальное окно с формами входа, регистрации и напоминанием пароля
|
||||
*
|
||||
* @styles css/modals.css
|
||||
*}
|
||||
|
||||
{extends 'components/modal/modal.tpl'}
|
||||
|
@ -12,11 +10,11 @@
|
|||
{block 'modal_attributes'}data-modal-center="false"{/block}
|
||||
|
||||
{block 'modal_content'}
|
||||
{if ! Config::Get('general.reg.invite')}
|
||||
{include 'components/auth/auth.registration.tpl' assign=auth_tab_reg}
|
||||
{else}
|
||||
{include 'components/auth/auth.invite.tpl' assign=auth_tab_reg}
|
||||
{/if}
|
||||
{if ! Config::Get('general.reg.invite')}
|
||||
{include 'components/auth/auth.registration.tpl' assign=auth_tab_reg}
|
||||
{else}
|
||||
{include 'components/auth/auth.invite.tpl' assign=auth_tab_reg}
|
||||
{/if}
|
||||
|
||||
{include 'components/auth/auth.login.tpl' assign=auth_tab_login}
|
||||
{include 'components/auth/auth.reset.tpl' assign=auth_tab_reset}
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
# Компонент autocomplete
|
|
@ -0,0 +1 @@
|
|||
# Компонент badge
|
|
@ -0,0 +1 @@
|
|||
# Компонент block
|
|
@ -0,0 +1 @@
|
|||
# Компонент blog
|
|
@ -1,98 +1,91 @@
|
|||
{**
|
||||
* Форма добавления/редактирования
|
||||
*
|
||||
* @param object $blog
|
||||
*}
|
||||
|
||||
{$blog = $smarty.local.blog}
|
||||
|
||||
<form method="post" enctype="multipart/form-data" class="js-form-validate">
|
||||
{hook run='form_add_blog_begin'}
|
||||
{hook run='form_add_blog_begin'}
|
||||
|
||||
{* Название блога *}
|
||||
{include 'components/field/field.text.tpl'
|
||||
name = 'blog_title'
|
||||
rules = [ 'required' => true, 'rangelength' => "[2,200]" ]
|
||||
note = $aLang.blog.add.fields.title.note
|
||||
label = $aLang.blog.add.fields.title.label}
|
||||
|
||||
{* URL блога *}
|
||||
{include 'components/field/field.text.tpl'
|
||||
name = 'blog_url'
|
||||
rules = [ 'required' => true, 'type' => 'alphanum', 'rangelength' => '[2,50]' ]
|
||||
isDisabled = $_aRequest.blog_id && ! $oUserCurrent->isAdministrator()
|
||||
note = $aLang.blog.add.fields.url.note
|
||||
label = $aLang.blog.add.fields.url.label}
|
||||
|
||||
{* Категория блога *}
|
||||
{if Config::Get('module.blog.category_allow') && ($oUserCurrent->isAdministrator() or ! Config::Get('module.blog.category_only_admin'))}
|
||||
{* Подключаем блок для управления категориями *}
|
||||
{insert name='block' block='fieldCategory' params=[ 'target' => $blog, 'entity' => 'ModuleBlog_EntityBlog' ]}
|
||||
{/if}
|
||||
|
||||
{* Тип блога *}
|
||||
{include 'components/field/field.select.tpl'
|
||||
name = 'blog_type'
|
||||
label = $aLang.blog.add.fields.type.label
|
||||
note = $aLang.blog.add.fields.type.note_open
|
||||
inputClasses = 'width-200 js-blog-add-type'
|
||||
selectedValue = $_aRequest.blog_type
|
||||
items = [
|
||||
[ 'value' => 'open', 'text' => $aLang.blog.add.fields.type.value_open ],
|
||||
[ 'value' => 'close', 'text' => $aLang.blog.add.fields.type.value_close ]
|
||||
]}
|
||||
|
||||
{* Описание блога *}
|
||||
{include 'components/editor/editor.tpl'
|
||||
set = 'light'
|
||||
mediaTargetType = 'blog'
|
||||
name = 'blog_description'
|
||||
rules = [ 'required' => true, 'rangelength' => '[10,3000]' ]
|
||||
inputClasses = 'js-editor-default'
|
||||
label = $aLang.blog.add.fields.description.label}
|
||||
|
||||
{* Ограничение по рейтингу *}
|
||||
{include 'components/field/field.text.tpl'
|
||||
name = 'blog_limit_rating_topic'
|
||||
rules = [ 'required' => true, 'type' => 'number' ]
|
||||
value = '0'
|
||||
inputClasses = 'width-100'
|
||||
note = $aLang.blog.add.fields.rating.note
|
||||
label = $aLang.blog.add.fields.rating.label}
|
||||
|
||||
{* Аватар *}
|
||||
{if $blog && $blog->getAvatar()}
|
||||
{$uploadedImages = []}
|
||||
|
||||
{foreach Config::Get('module.blog.avatar_size') as $size}
|
||||
{if $image = $blog->getAvatarPath( $size )}
|
||||
{$uploadedImages[] = $image}
|
||||
{/if}
|
||||
{/foreach}
|
||||
{/if}
|
||||
|
||||
{include 'components/field/field.image.tpl'
|
||||
name = 'avatar'
|
||||
removeName = 'avatar_delete'
|
||||
uploadedFiles = $uploadedImages
|
||||
label = $aLang.blog.add.fields.avatar.label}
|
||||
|
||||
|
||||
{* Название блога *}
|
||||
{include 'components/field/field.text.tpl'
|
||||
name = 'blog_title'
|
||||
rules = [ 'required' => true, 'rangelength' => "[2,200]" ]
|
||||
note = $aLang.blog.add.fields.title.note
|
||||
label = $aLang.blog.add.fields.title.label}
|
||||
{hook run='form_add_blog_end'}
|
||||
|
||||
{* URL блога *}
|
||||
{include 'components/field/field.text.tpl'
|
||||
name = 'blog_url'
|
||||
rules = [ 'required' => true, 'type' => 'alphanum', 'rangelength' => '[2,50]' ]
|
||||
isDisabled = $_aRequest.blog_id && ! $oUserCurrent->isAdministrator()
|
||||
note = $aLang.blog.add.fields.url.note
|
||||
label = $aLang.blog.add.fields.url.label}
|
||||
{* Скрытые поля *}
|
||||
{include 'components/field/field.hidden.security_key.tpl'}
|
||||
|
||||
|
||||
{* Категория блога *}
|
||||
{if Config::Get('module.blog.category_allow') and ($oUserCurrent->isAdministrator() or ! Config::Get('module.blog.category_only_admin'))}
|
||||
{* Подключаем блок для управления категориями *}
|
||||
{insert name='block' block='categoryUpdate' params=[ 'target' => $oBlogEdit, 'entity' => 'ModuleBlog_EntityBlog' ]}
|
||||
{/if}
|
||||
|
||||
|
||||
{* Тип блога *}
|
||||
{include 'components/field/field.select.tpl'
|
||||
name = 'blog_type'
|
||||
label = $aLang.blog.add.fields.type.label
|
||||
note = $aLang.blog.add.fields.type.note_open
|
||||
inputClasses = 'width-200 js-blog-add-type'
|
||||
selectedValue = $_aRequest.blog_type
|
||||
items = [
|
||||
[ 'value' => 'open', 'text' => $aLang.blog.add.fields.type.value_open ],
|
||||
[ 'value' => 'close', 'text' => $aLang.blog.add.fields.type.value_close ]
|
||||
]}
|
||||
|
||||
|
||||
{* Описание блога *}
|
||||
{include 'components/editor/editor.tpl'
|
||||
set = 'light'
|
||||
mediaTargetType = 'blog'
|
||||
name = 'blog_description'
|
||||
rules = [ 'required' => true, 'rangelength' => '[10,3000]' ]
|
||||
inputClasses = 'js-editor-default'
|
||||
label = $aLang.blog.add.fields.description.label}
|
||||
|
||||
|
||||
{* Ограничение по рейтингу *}
|
||||
{include 'components/field/field.text.tpl'
|
||||
name = 'blog_limit_rating_topic'
|
||||
rules = [ 'required' => true, 'type' => 'number' ]
|
||||
value = '0'
|
||||
inputClasses = 'width-100'
|
||||
note = $aLang.blog.add.fields.rating.note
|
||||
label = $aLang.blog.add.fields.rating.label}
|
||||
|
||||
|
||||
{* Аватар *}
|
||||
{if $oBlogEdit and $oBlogEdit->getAvatar()}
|
||||
{$uploadedImages = []}
|
||||
|
||||
{foreach Config::Get('module.blog.avatar_size') as $size}
|
||||
{if $image = $oBlogEdit->getAvatarPath( $size )}
|
||||
{$uploadedImages[] = $image}
|
||||
{/if}
|
||||
{/foreach}
|
||||
{/if}
|
||||
|
||||
{include 'components/field/field.image.tpl'
|
||||
name = 'avatar'
|
||||
removeName = 'avatar_delete'
|
||||
uploadedFiles = $uploadedImages
|
||||
label = $aLang.blog.add.fields.avatar.label}
|
||||
|
||||
|
||||
{hook run='form_add_blog_end'}
|
||||
|
||||
|
||||
{* Скрытые поля *}
|
||||
{include 'components/field/field.hidden.security_key.tpl'}
|
||||
|
||||
|
||||
{* Кнопки *}
|
||||
{if $sEvent == 'add'}
|
||||
{$sSubmitInputText = $aLang.common.create}
|
||||
{else}
|
||||
{$sSubmitInputText = $aLang.common.save}
|
||||
{/if}
|
||||
|
||||
{include 'components/button/button.tpl' name='submit_blog_add' text=$sSubmitInputText mods='primary'}
|
||||
{* Кнопки *}
|
||||
{include 'components/button/button.tpl'
|
||||
name = 'submit_blog_add'
|
||||
text = {lang "{( $sEvent == 'add' ) ? 'common.create' : 'common.save'}"}
|
||||
mods = 'primary'}
|
||||
</form>
|
|
@ -1,50 +1,53 @@
|
|||
{**
|
||||
* Управление пользователями блога
|
||||
*
|
||||
* @param object $users
|
||||
* @param array $pagination
|
||||
*}
|
||||
|
||||
{if $aBlogUsers}
|
||||
<form method="post" enctype="multipart/form-data">
|
||||
<table class="table">
|
||||
<thead>
|
||||
<tr>
|
||||
<th class="cell-name"></th>
|
||||
<th class="ta-c">{$aLang.blog.admin.role_administrator}</th>
|
||||
<th class="ta-c">{$aLang.blog.admin.role_moderator}</th>
|
||||
<th class="ta-c">{$aLang.blog.admin.role_reader}</th>
|
||||
<th class="ta-c">{$aLang.blog.admin.role_banned}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
{if $smarty.local.users}
|
||||
<form method="post" enctype="multipart/form-data">
|
||||
<table class="table">
|
||||
<thead>
|
||||
<tr>
|
||||
<th class="cell-name"></th>
|
||||
<th class="ta-c">{$aLang.blog.admin.role_administrator}</th>
|
||||
<th class="ta-c">{$aLang.blog.admin.role_moderator}</th>
|
||||
<th class="ta-c">{$aLang.blog.admin.role_reader}</th>
|
||||
<th class="ta-c">{$aLang.blog.admin.role_banned}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
|
||||
<tbody>
|
||||
{foreach $aBlogUsers as $oBlogUser}
|
||||
{$oUser = $oBlogUser->getUser()}
|
||||
<tbody>
|
||||
{foreach $smarty.local.users as $blogUser}
|
||||
{$user = $blogUser->getUser()}
|
||||
|
||||
<tr>
|
||||
<td class="cell-name">
|
||||
{include 'components/user/user-item.tpl' oUser=$oUser}
|
||||
</td>
|
||||
<tr>
|
||||
<td class="cell-name">
|
||||
{include 'components/user/user-item.tpl' oUser=$user}
|
||||
</td>
|
||||
|
||||
{if $oUser->getId() == $oUserCurrent->getId()}
|
||||
<td colspan="10" class="ta-c">—</td>
|
||||
{else}
|
||||
<td class="ta-c"><input type="radio" name="user_rank[{$oUser->getId()}]" value="administrator" {if $oBlogUser->getIsAdministrator()}checked{/if} /></td>
|
||||
<td class="ta-c"><input type="radio" name="user_rank[{$oUser->getId()}]" value="moderator" {if $oBlogUser->getIsModerator()}checked{/if} /></td>
|
||||
<td class="ta-c"><input type="radio" name="user_rank[{$oUser->getId()}]" value="reader" {if $oBlogUser->getUserRole() == $BLOG_USER_ROLE_USER}checked{/if} /></td>
|
||||
<td class="ta-c"><input type="radio" name="user_rank[{$oUser->getId()}]" value="ban" {if $oBlogUser->getUserRole() == $BLOG_USER_ROLE_BAN}checked{/if} /></td>
|
||||
{/if}
|
||||
</tr>
|
||||
{/foreach}
|
||||
</tbody>
|
||||
</table>
|
||||
{if $user->getId() == $oUserCurrent->getId()}
|
||||
<td colspan="10" class="ta-c">—</td>
|
||||
{else}
|
||||
<td class="ta-c"><input type="radio" name="user_rank[{$user->getId()}]" value="administrator" {if $user->getIsAdministrator()}checked{/if} /></td>
|
||||
<td class="ta-c"><input type="radio" name="user_rank[{$user->getId()}]" value="moderator" {if $user->getIsModerator()}checked{/if} /></td>
|
||||
<td class="ta-c"><input type="radio" name="user_rank[{$user->getId()}]" value="reader" {if $user->getUserRole() == $BLOG_USER_ROLE_USER}checked{/if} /></td>
|
||||
<td class="ta-c"><input type="radio" name="user_rank[{$user->getId()}]" value="ban" {if $user->getUserRole() == $BLOG_USER_ROLE_BAN}checked{/if} /></td>
|
||||
{/if}
|
||||
</tr>
|
||||
{/foreach}
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
{* Скрытые поля *}
|
||||
{include 'components/field/field.hidden.security_key.tpl'}
|
||||
{* Скрытые поля *}
|
||||
{include 'components/field/field.hidden.security_key.tpl'}
|
||||
|
||||
{* Кнопки *}
|
||||
{include 'components/button/button.tpl' name='submit_blog_admin' text=$aLang.common.save mods='primary'}
|
||||
</form>
|
||||
{* Кнопки *}
|
||||
{include 'components/button/button.tpl' name='submit_blog_admin' text=$aLang.common.save mods='primary'}
|
||||
</form>
|
||||
|
||||
{include 'components/pagination/pagination.tpl' paging=$aPaging}
|
||||
{include 'components/pagination/pagination.tpl' paging=$smarty.local.pagination}
|
||||
{else}
|
||||
{include 'components/alert/alert.tpl' text=$aLang.blog.admin.alerts.empty mods='empty'}
|
||||
{include 'components/alert/alert.tpl' text=$aLang.blog.admin.alerts.empty mods='empty'}
|
||||
{/if}
|
|
@ -15,7 +15,7 @@
|
|||
{/block}
|
||||
|
||||
{block 'block_content'}
|
||||
{if $oUserCurrent and ($oUserCurrent->getRating() > {cfg name='acl.create.blog.rating'} or $oUserCurrent->isAdministrator())}
|
||||
{if $oUserCurrent && ($oUserCurrent->getRating() > {cfg name='acl.create.blog.rating'} or $oUserCurrent->isAdministrator())}
|
||||
<p>{$aLang.blog.can_add}</p>
|
||||
|
||||
{include 'components/button/button.tpl' url="{router page='blog'}add/" mods='primary large' text=$aLang.blog.create_blog}
|
||||
|
|
|
@ -1,6 +1,14 @@
|
|||
{**
|
||||
* Блог в списке блогов
|
||||
*
|
||||
* @param object $blog
|
||||
*}
|
||||
|
||||
{extends 'components/item/item.tpl'}
|
||||
|
||||
{block 'options' append}
|
||||
{$blog = $smarty.local.blog}
|
||||
|
||||
{* Заголовок *}
|
||||
{capture 'blog_list_item_title'}
|
||||
{if $blog->getType() == 'close'}
|
||||
|
|
|
@ -1,35 +1,39 @@
|
|||
{**
|
||||
* Список блогов
|
||||
*
|
||||
* @styles css/blog.css
|
||||
* @scripts <frontend>/common/js/blog.js
|
||||
* @param array $blogs
|
||||
* @param array $pagination
|
||||
* @param boolean $useMore
|
||||
* @param boolean $hideMore
|
||||
* @param integer $searchCount
|
||||
* @param string $textEmpty
|
||||
*}
|
||||
|
||||
|
||||
{* Список блогов *}
|
||||
{if $aBlogs}
|
||||
{if $iSearchCount}
|
||||
<h3 class="h3">{lang name='blog.search.result_title' count=$iSearchCount plural=true}</h3>
|
||||
{if $smarty.local.blogs}
|
||||
{if $smarty.local.searchCount}
|
||||
<h3 class="h3">{lang name='blog.search.result_title' count=$smarty.local.searchCount plural=true}</h3>
|
||||
{/if}
|
||||
|
||||
{* Список блогов *}
|
||||
<ul class="object-list object-list-actions blog-list js-more-blogs-container">
|
||||
{foreach $aBlogs as $blog}
|
||||
{foreach $smarty.local.blogs as $blog}
|
||||
{include './blog-list-item.tpl' blog=$blog}
|
||||
{/foreach}
|
||||
</ul>
|
||||
|
||||
{* Кнопка подгрузки *}
|
||||
{if $bUseMore}
|
||||
{if ! $bHideMore}
|
||||
{if $smarty.local.useMore}
|
||||
{if ! $smarty.local.hideMore}
|
||||
{include 'components/more/more.tpl'
|
||||
classes = 'js-more-search'
|
||||
target = '.js-more-blogs-container'
|
||||
attributes = 'data-search-type="blogs" data-proxy-page-next="2"'}
|
||||
{/if}
|
||||
{else}
|
||||
{include 'components/pagination/pagination.tpl' paging=$aPaging}
|
||||
{include 'components/pagination/pagination.tpl' paging=$smarty.local.pagination}
|
||||
{/if}
|
||||
{else}
|
||||
{include 'components/alert/alert.tpl' text=(($sBlogsEmptyList) ? $sBlogsEmptyList : $aLang.blog.alerts.empty) mods='empty'}
|
||||
{include 'components/alert/alert.tpl' text=(($smarty.local.textEmpty) ? $smarty.local.textEmpty : $aLang.blog.alerts.empty) mods='empty'}
|
||||
{/if}
|
|
@ -16,8 +16,8 @@
|
|||
{$blog = $smarty.local.blog}
|
||||
|
||||
{* Подключаем модальное окно удаления блога если пользователь админ *}
|
||||
{if $oUserCurrent and $oUserCurrent->isAdministrator()}
|
||||
{include './modal.blog-delete.tpl'}
|
||||
{if $oUserCurrent && $oUserCurrent->isAdministrator()}
|
||||
{include './modals/modal.blog-delete.tpl'}
|
||||
{/if}
|
||||
|
||||
{* Является ли пользователь администратором или управляющим блога *}
|
||||
|
@ -25,70 +25,70 @@
|
|||
|
||||
|
||||
{* Блог *}
|
||||
<div class="{$component} {mod name=$component mods=$mods default=$defaultMod} {$smarty.local.classes}" data-id="{$blog->getId()}">
|
||||
<header class="{$component}-header">
|
||||
{* Голосование *}
|
||||
{block 'blog_vote'}
|
||||
{include 'components/vote/vote.tpl'
|
||||
classes = 'js-vote-blog'
|
||||
mods = 'large'
|
||||
target = $blog
|
||||
isLocked = $isBlogAdmin
|
||||
showLabel = true}
|
||||
{/block}
|
||||
<div class="{$component} {mod name=$component mods=$smarty.local.mods} {$smarty.local.classes}" data-id="{$blog->getId()}" {$smarty.local.attributes}>
|
||||
<header class="{$component}-header">
|
||||
{* Голосование *}
|
||||
{block 'blog_vote'}
|
||||
{include 'components/vote/vote.tpl'
|
||||
classes = 'js-vote-blog'
|
||||
mods = 'large'
|
||||
target = $blog
|
||||
isLocked = $isBlogAdmin
|
||||
showLabel = true}
|
||||
{/block}
|
||||
|
||||
{* Заголовок *}
|
||||
<h2 class="page-header blog-title">
|
||||
{if $blog->getType() == 'close'}
|
||||
<i title="{$aLang.blog.private}" class="icon icon-lock"></i>
|
||||
{/if}
|
||||
{* Заголовок *}
|
||||
<h2 class="page-header blog-title">
|
||||
{if $blog->getType() == 'close'}
|
||||
<i title="{$aLang.blog.private}" class="icon icon-lock"></i>
|
||||
{/if}
|
||||
|
||||
{$blog->getTitle()|escape}
|
||||
</h2>
|
||||
</header>
|
||||
{$blog->getTitle()|escape}
|
||||
</h2>
|
||||
</header>
|
||||
|
||||
|
||||
{* Информация о блоге *}
|
||||
<div class="{$component}-content">
|
||||
{* Описание *}
|
||||
<div class="{$component}-description text">
|
||||
{$blog->getDescription()}
|
||||
</div>
|
||||
{* Информация о блоге *}
|
||||
<div class="{$component}-content">
|
||||
{* Описание *}
|
||||
<div class="{$component}-description text">
|
||||
{$blog->getDescription()}
|
||||
</div>
|
||||
|
||||
{* Информация *}
|
||||
{$info = [
|
||||
[ 'label' => $aLang.blog.date_created, 'content' => "{date_format date=$blog->getDateAdd() hours_back='12' minutes_back='60' now='60' day='day H:i' format='j F Y'}" ],
|
||||
[ 'label' => $aLang.blog.topics_total, 'content' => $blog->getCountTopic() ],
|
||||
[ 'label' => $aLang.blog.rating_limit, 'content' => $blog->getLimitRatingTopic() ]
|
||||
]}
|
||||
{* Информация *}
|
||||
{$info = [
|
||||
[ 'label' => $aLang.blog.date_created, 'content' => "{date_format date=$blog->getDateAdd() hours_back='12' minutes_back='60' now='60' day='day H:i' format='j F Y'}" ],
|
||||
[ 'label' => $aLang.blog.topics_total, 'content' => $blog->getCountTopic() ],
|
||||
[ 'label' => $aLang.blog.rating_limit, 'content' => $blog->getLimitRatingTopic() ]
|
||||
]}
|
||||
|
||||
{if $blog->category->getCategory()}
|
||||
{$info[] = [ 'label' => "{$aLang.blog.categories.category}:", 'content' => $blog->category->getCategory()->getTitle() ]}
|
||||
{/if}
|
||||
|
||||
{include 'components/info-list/info-list.tpl' list=$info}
|
||||
</div>
|
||||
{include 'components/info-list/info-list.tpl' list=$info}
|
||||
</div>
|
||||
|
||||
|
||||
{* Управление *}
|
||||
{if $oUserCurrent && $isBlogAdmin}
|
||||
{$aActionbarItems = [ [ 'icon' => 'icon-edit', 'url' => "{router page='blog'}edit/{$blog->getId()}/", 'text' => $aLang.common.edit ] ]}
|
||||
{* Управление *}
|
||||
{if $oUserCurrent && $isBlogAdmin}
|
||||
{$actionbarItems = [ [ 'icon' => 'icon-edit', 'url' => "{router page='blog'}edit/{$blog->getId()}/", 'text' => $aLang.common.edit ] ]}
|
||||
|
||||
{if $oUserCurrent->isAdministrator()}
|
||||
{$aActionbarItems[] = [
|
||||
'icon' => 'icon-trash',
|
||||
'attributes' => 'data-type="modal-toggle" data-modal-target="modal-blog-delete"',
|
||||
'text' => $aLang.common.remove
|
||||
]}
|
||||
{else}
|
||||
{$aActionbarItems[] = [
|
||||
'icon' => 'icon-trash',
|
||||
'url' => "{router page='blog'}delete/{$blog->getId()}/?security_ls_key={$LIVESTREET_SECURITY_KEY}",
|
||||
'classes' => 'js-blog-remove',
|
||||
'text' => $aLang.common.remove
|
||||
]}
|
||||
{/if}
|
||||
{if $oUserCurrent->isAdministrator()}
|
||||
{$actionbarItems[] = [
|
||||
'icon' => 'icon-trash',
|
||||
'attributes' => 'data-type="modal-toggle" data-modal-target="modal-blog-delete"',
|
||||
'text' => $aLang.common.remove
|
||||
]}
|
||||
{else}
|
||||
{$actionbarItems[] = [
|
||||
'icon' => 'icon-trash',
|
||||
'url' => "{router page='blog'}delete/{$blog->getId()}/?security_ls_key={$LIVESTREET_SECURITY_KEY}",
|
||||
'classes' => 'js-blog-remove',
|
||||
'text' => $aLang.common.remove
|
||||
]}
|
||||
{/if}
|
||||
|
||||
{include 'components/actionbar/actionbar.tpl' items=$aActionbarItems}
|
||||
{/if}
|
||||
{include 'components/actionbar/actionbar.tpl' items=$actionbarItems}
|
||||
{/if}
|
||||
</div>
|
|
@ -1,9 +1,6 @@
|
|||
/**
|
||||
* Блог
|
||||
*
|
||||
* @template actions/ActionBlog/blog.tpl
|
||||
* @scripts <frontend>/common/js/blog.js
|
||||
*
|
||||
* @license GNU General Public License, version 2
|
||||
* @copyright 2013 OOO "ЛС-СОФТ" {@link http://livestreetcms.com}
|
||||
* @author Denis Shakhov <denis.shakhov@gmail.com>
|
||||
|
@ -19,20 +16,39 @@
|
|||
}
|
||||
|
||||
/* Хидер */
|
||||
.blog-header { position: relative; padding: 0 0 15px 0; }
|
||||
|
||||
.blog-header .blog-title { margin-bottom: 7px; }
|
||||
.blog-header .blog-title i { position: relative; top: -2px; vertical-align: middle; }
|
||||
|
||||
.blog-header .vote { position: absolute; top: -15px; right: 0; }
|
||||
.blog-header {
|
||||
position: relative;
|
||||
padding: 0 0 15px 0;
|
||||
}
|
||||
.blog-header .blog-title {
|
||||
margin-bottom: 7px;
|
||||
}
|
||||
.blog-header .blog-title i {
|
||||
position: relative;
|
||||
top: -2px;
|
||||
vertical-align: middle;
|
||||
}
|
||||
.blog-header .vote {
|
||||
position: absolute;
|
||||
top: -15px;
|
||||
right: 0;
|
||||
}
|
||||
|
||||
/* Контент */
|
||||
.blog .actionbar { margin-bottom: 0; margin-top: 30px; }
|
||||
|
||||
.blog-description { margin-bottom: 20px; }
|
||||
.blog .actionbar {
|
||||
margin-bottom: 0;
|
||||
margin-top: 30px;
|
||||
}
|
||||
.blog-description {
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Список блогов
|
||||
*/
|
||||
.blog-list-item-join { position: absolute; top: 0; right: 0; }
|
||||
.blog-list-item-join {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
right: 0;
|
||||
}
|
|
@ -1,10 +1,7 @@
|
|||
{**
|
||||
* Кнопка Вступить / Покинуть блог
|
||||
*
|
||||
* @param object $blog Блог
|
||||
* @param object $oUserCurrent Текущий пользователь
|
||||
*
|
||||
* @scripts <framework>/js/livestreet/blog.js
|
||||
* @param object $blog Блог
|
||||
*}
|
||||
|
||||
{if $oUserCurrent && $oUserCurrent->getId() != $blog->getOwnerId() && $blog->getType() == 'open'}
|
||||
|
|
|
@ -1,40 +0,0 @@
|
|||
{**
|
||||
* Удаление блога
|
||||
*
|
||||
* @styles css/modals.css
|
||||
*}
|
||||
|
||||
{extends 'components/modal/modal.tpl'}
|
||||
|
||||
{block 'modal_id'}modal-blog-delete{/block}
|
||||
{block 'modal_class'}modal-blog-delete js-modal-default{/block}
|
||||
{block 'modal_title'}{$aLang.blog.remove.title}{/block}
|
||||
|
||||
{block 'modal_content'}
|
||||
<form action="{router page='blog'}delete/{$oBlog->getId()}/" method="POST" id="js-blog-remove-form">
|
||||
{* Переместить топики в блог *}
|
||||
{$aBlogsCustom = [
|
||||
[ 'value' => -1, 'text' => $aLang.blog.remove.remove_topics ]
|
||||
]}
|
||||
|
||||
{foreach $aBlogs as $oBlog}
|
||||
{$aBlogsCustom[] = [
|
||||
'value' => $oBlog->getId(),
|
||||
'text' => $oBlog->getTitle()|escape
|
||||
]}
|
||||
{/foreach}
|
||||
|
||||
{include 'components/field/field.select.tpl'
|
||||
name = 'topic_move_to'
|
||||
label = $aLang.blog.remove.move_to
|
||||
items = $aBlogsCustom}
|
||||
|
||||
|
||||
{* Скрытые поля *}
|
||||
{include 'components/field/field.hidden.security_key.tpl'}
|
||||
</form>
|
||||
{/block}
|
||||
|
||||
{block 'modal_footer_begin'}
|
||||
{include 'components/button/button.tpl' form='js-blog-remove-form' text=$aLang.common.remove mods='primary'}
|
||||
{/block}
|
|
@ -0,0 +1,40 @@
|
|||
{**
|
||||
* Удаление блога
|
||||
*
|
||||
* @styles css/modals.css
|
||||
*}
|
||||
|
||||
{extends 'components/modal/modal.tpl'}
|
||||
|
||||
{block 'modal_id'}modal-blog-delete{/block}
|
||||
{block 'modal_class'}modal-blog-delete js-modal-default{/block}
|
||||
{block 'modal_title'}{$aLang.blog.remove.title}{/block}
|
||||
|
||||
{block 'modal_content'}
|
||||
<form action="{router page='blog'}delete/{$oBlog->getId()}/" method="POST" id="js-blog-remove-form">
|
||||
{* Переместить топики в блог *}
|
||||
{$aBlogsCustom = [
|
||||
[ 'value' => -1, 'text' => $aLang.blog.remove.remove_topics ]
|
||||
]}
|
||||
|
||||
{foreach $aBlogs as $oBlog}
|
||||
{$aBlogsCustom[] = [
|
||||
'value' => $oBlog->getId(),
|
||||
'text' => $oBlog->getTitle()|escape
|
||||
]}
|
||||
{/foreach}
|
||||
|
||||
{include 'components/field/field.select.tpl'
|
||||
name = 'topic_move_to'
|
||||
label = $aLang.blog.remove.move_to
|
||||
items = $aBlogsCustom}
|
||||
|
||||
|
||||
{* Скрытые поля *}
|
||||
{include 'components/field/field.hidden.security_key.tpl'}
|
||||
</form>
|
||||
{/block}
|
||||
|
||||
{block 'modal_footer_begin'}
|
||||
{include 'components/button/button.tpl' form='js-blog-remove-form' text=$aLang.common.remove mods='primary'}
|
||||
{/block}
|
|
@ -1,15 +1,13 @@
|
|||
{**
|
||||
* Форма поиска блогов
|
||||
*
|
||||
* @styles css/forms.css
|
||||
*}
|
||||
|
||||
{include 'components/search-form/search-form.tpl'
|
||||
name = 'blog'
|
||||
method = 'post'
|
||||
placeholder = $aLang.blog.search.placeholder
|
||||
classes = 'js-tag-search-form'
|
||||
inputClasses = 'js-search-ajax-option js-search-text-main'
|
||||
inputAttributes = 'data-type="blogs"'
|
||||
inputName = 'blog_title'
|
||||
noSubmitButton = true}
|
||||
name = 'blog'
|
||||
method = 'post'
|
||||
placeholder = $aLang.blog.search.placeholder
|
||||
classes = 'js-tag-search-form'
|
||||
inputClasses = 'js-search-ajax-option js-search-text-main'
|
||||
inputAttributes = 'data-type="blogs"'
|
||||
inputName = 'blog_title'
|
||||
noSubmitButton = true}
|
|
@ -5,7 +5,7 @@
|
|||
|
||||
{extends 'components/user/user-list-small-item.tpl'}
|
||||
|
||||
{block 'components/user_list_small/user_list_small_item_actions'}
|
||||
{block 'user_list_small_item_actions'}
|
||||
<li class="icon-repeat js-blog-invite-user-repeat" title="{$aLang.blog.invite.repeat}" data-user-id="{$iUserId}"></li>
|
||||
|
||||
{$smarty.block.parent}
|
||||
|
|
|
@ -50,7 +50,7 @@
|
|||
{$items = [ [ 'classes' => 'js-comments-fold-all-toggle', 'text' => $aLang.comments.folding.fold_all ] ]}
|
||||
|
||||
{* Подписка на комментарии *}
|
||||
{if $bAllowSubscribe and $oUserCurrent}
|
||||
{if $bAllowSubscribe && $oUserCurrent}
|
||||
{* Подписан пользователь на комментарии или нет *}
|
||||
{$bIsSubscribed = $oSubscribeComment && $oSubscribeComment->getStatus()}
|
||||
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
# Компонент content
|
|
@ -0,0 +1 @@
|
|||
# Компонент crop
|
|
@ -0,0 +1 @@
|
|||
# Компонент css-helpers
|
|
@ -0,0 +1 @@
|
|||
# Компонент css-reset
|
|
@ -0,0 +1 @@
|
|||
# Компонент editor
|
|
@ -8,9 +8,6 @@
|
|||
* @param string $isActive
|
||||
* @param boolean $hideZeroCounter (true)
|
||||
*
|
||||
* @styles assets/css/common.css
|
||||
* @scripts <common>/js/favourite.js
|
||||
*
|
||||
* TODO: Текстовая версия
|
||||
*}
|
||||
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
|
||||
{if $aGeoCountries}
|
||||
{foreach $aGeoCountries as $country}
|
||||
<option value="{$country->getId()}" {if $place and $place->getCountryId() == $country->getId()}selected="selected"{/if}>{$country->getName()}</option>
|
||||
<option value="{$country->getId()}" {if $place && $place->getCountryId() == $country->getId()}selected="selected"{/if}>{$country->getName()}</option>
|
||||
{/foreach}
|
||||
{/if}
|
||||
</select></p>
|
||||
|
@ -24,7 +24,7 @@
|
|||
|
||||
{if $aGeoRegions}
|
||||
{foreach $aGeoRegions as $region}
|
||||
<option value="{$region->getId()}" {if $place and $place->getRegionId() == $region->getId()}selected="selected"{/if}>{$region->getName()}</option>
|
||||
<option value="{$region->getId()}" {if $place && $place->getRegionId() == $region->getId()}selected="selected"{/if}>{$region->getName()}</option>
|
||||
{/foreach}
|
||||
{/if}
|
||||
</select></p>
|
||||
|
@ -34,7 +34,7 @@
|
|||
|
||||
{if $aGeoCities}
|
||||
{foreach $aGeoCities as $city}
|
||||
<option value="{$city->getId()}" {if $place and $place->getCityId() == $city->getId()}selected="selected"{/if}>{$city->getName()}</option>
|
||||
<option value="{$city->getId()}" {if $place && $place->getCityId() == $city->getId()}selected="selected"{/if}>{$city->getName()}</option>
|
||||
{/foreach}
|
||||
{/if}
|
||||
</select></p>
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
# Компонент forms
|
|
@ -0,0 +1 @@
|
|||
# Компонент grid
|
|
@ -0,0 +1 @@
|
|||
# Компонент icons-contact
|
|
@ -0,0 +1 @@
|
|||
# Компонент icons
|
|
@ -0,0 +1 @@
|
|||
# Компонент item
|
|
@ -0,0 +1 @@
|
|||
# Компонент layout
|
|
@ -0,0 +1 @@
|
|||
# Компонент ls-core
|
|
@ -0,0 +1 @@
|
|||
# Компонент ls-vendor
|
|
@ -0,0 +1 @@
|
|||
# Компонент modal-create
|
|
@ -0,0 +1 @@
|
|||
# Компонент note
|
|
@ -0,0 +1 @@
|
|||
# Компонент notification
|
|
@ -0,0 +1 @@
|
|||
# Компонент page-header
|
|
@ -38,7 +38,7 @@
|
|||
{**
|
||||
* Страницы
|
||||
*}
|
||||
{if $_paging and $_paging.iCountPage > 1}
|
||||
{if $_paging && $_paging.iCountPage > 1}
|
||||
<nav class="{$component} {mod name=$component mods=$smarty.local.mods} {$smarty.local.classes} js-{$component}" role="navigation" {$smarty.local.attributes}>
|
||||
{* Следущая / предыдущая страница *}
|
||||
<ul class="{$component}-list">
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
# Компонент perfomance
|
|
@ -2,7 +2,7 @@
|
|||
* Информация о производительности движка
|
||||
*}
|
||||
|
||||
{if $bIsShowStatsPerformance and $oUserCurrent and $oUserCurrent->isAdministrator()}
|
||||
{if $bIsShowStatsPerformance && $oUserCurrent && $oUserCurrent->isAdministrator()}
|
||||
{$stats = $smarty.local.stats}
|
||||
|
||||
<div class="alert alert--info performance">
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
# Компонент poll
|
|
@ -15,7 +15,7 @@
|
|||
|
||||
|
||||
{* Кол-во вариантов которые может выбрать пользователь *}
|
||||
{if $oPoll and $oPoll->getCountVote()}
|
||||
{if $oPoll && $oPoll->getCountVote()}
|
||||
{$bDisableChangeType = true}
|
||||
{/if}
|
||||
|
||||
|
@ -33,7 +33,7 @@
|
|||
name = 'poll[type]'
|
||||
value = 'many'
|
||||
label = $aLang.poll.form.fields.type.label_many
|
||||
checked = $oPoll and $oPoll->getCountAnswerMax() > 1
|
||||
checked = $oPoll && $oPoll->getCountAnswerMax() > 1
|
||||
isDisabled = $bDisableChangeType}
|
||||
|
||||
{include 'components/field/field.text.tpl'
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
# Компонент progressbar
|
|
@ -0,0 +1 @@
|
|||
# Компонент report
|
|
@ -0,0 +1 @@
|
|||
# Компонент search-ajax
|
|
@ -0,0 +1 @@
|
|||
# Компонент search-form
|
|
@ -0,0 +1 @@
|
|||
# Компонент search
|
|
@ -0,0 +1 @@
|
|||
# Компонент sort
|
|
@ -0,0 +1 @@
|
|||
# Компонент subscribe
|
|
@ -0,0 +1 @@
|
|||
# Компонент table
|
|
@ -9,6 +9,7 @@
|
|||
.table {
|
||||
width: 100%;
|
||||
margin-bottom: 15px;
|
||||
border-top: 1px solid #eee;
|
||||
}
|
||||
.table th {
|
||||
text-align: left;
|
||||
|
@ -16,10 +17,10 @@
|
|||
}
|
||||
.table td, .table th {
|
||||
border-bottom: 1px solid #eee;
|
||||
padding: 10px;
|
||||
padding: 15px;
|
||||
}
|
||||
.table tr.active td {
|
||||
background: #CBF4BC;
|
||||
background: #F6F6FA;
|
||||
}
|
||||
.table a.asc:after {
|
||||
content: "▲";
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
# Компонент tags-favourite
|
|
@ -0,0 +1 @@
|
|||
# Компонент tags
|
|
@ -0,0 +1 @@
|
|||
# Компонент talk
|
|
@ -0,0 +1 @@
|
|||
# Компонент text
|
|
@ -0,0 +1 @@
|
|||
# Компонент toolbar-scrollnav
|
|
@ -0,0 +1 @@
|
|||
# Компонент toolbar-scrollup
|
|
@ -0,0 +1 @@
|
|||
# Компонент toolbar
|
|
@ -0,0 +1 @@
|
|||
# Компонент tooltip
|
|
@ -0,0 +1 @@
|
|||
# Компонент topic
|
|
@ -137,7 +137,7 @@
|
|||
id = {( $topic ) ? 'submit-edit-topic-publish' : 'submit-add-topic-publish' }
|
||||
mods = 'primary'
|
||||
classes = 'fl-r'
|
||||
text = $aLang.topic.add.button[ ( $sEvent == 'add' or ( $topic and $topic->getPublish() == 0 ) ) ? 'publish' : 'update' ]}
|
||||
text = $aLang.topic.add.button[ ( $sEvent == 'add' or ( $topic && $topic->getPublish() == 0 ) ) ? 'publish' : 'update' ]}
|
||||
|
||||
{* Превью *}
|
||||
{include 'components/button/button.tpl' type='button' classes='js-topic-preview-text-button' text=$aLang.common.preview_text}
|
||||
|
|
|
@ -62,7 +62,7 @@
|
|||
|
||||
{* Теги *}
|
||||
{block 'article_footer'}
|
||||
{if ! $isList and $topic->getTypeObject()->getParam('allow_tags')}
|
||||
{if ! $isList && $topic->getTypeObject()->getParam('allow_tags')}
|
||||
{$favourite = $topic->getFavourite()}
|
||||
|
||||
{if ! $isPreview}
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
# Компонент user-list-add
|
|
@ -9,7 +9,7 @@
|
|||
{block 'block_options' append}
|
||||
{$mods = "{$mods} profile-actions"}
|
||||
|
||||
{if ! $oUserCurrent or ( $oUserCurrent and $oUserCurrent->getId() == $oUserProfile->getId() )}
|
||||
{if ! $oUserCurrent or ( $oUserCurrent && $oUserCurrent->getId() == $oUserProfile->getId() )}
|
||||
{$show = false}
|
||||
{/if}
|
||||
{/block}
|
||||
|
|
|
@ -16,7 +16,7 @@
|
|||
{* Действия *}
|
||||
{if $bUserListSmallShowActions}
|
||||
<ul class="user-list-small-item-actions js-user-list-small-actions">
|
||||
{block 'components/user_list_small/user_list_small_item_actions'}
|
||||
{block 'user_list_small_item_actions'}
|
||||
{if $bUserListItemShowRemove|default:true}
|
||||
<li class="icon-remove js-user-list-add-user-remove" title="{$aLang.common.remove}" data-user-id="{$iUserId}"></li>
|
||||
{/if}
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
# Компонент userbar
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue