mirror of
https://github.com/Oreolek/ifhub.club.git
synced 2024-06-28 20:45:00 +03:00
новые хуки
This commit is contained in:
parent
1967503303
commit
c3df2d65d2
|
@ -687,7 +687,10 @@ class ActionTalk extends Action {
|
||||||
/**
|
/**
|
||||||
* Добавляем коммент
|
* Добавляем коммент
|
||||||
*/
|
*/
|
||||||
|
$this->Hook_Run('talk_comment_add_before', array('oCommentNew'=>$oCommentNew,'oCommentParent'=>$oCommentParent,'oTalk'=>$oTalk));
|
||||||
if ($this->Comment_AddComment($oCommentNew)) {
|
if ($this->Comment_AddComment($oCommentNew)) {
|
||||||
|
$this->Hook_Run('talk_comment_add_after', array('oCommentNew'=>$oCommentNew,'oCommentParent'=>$oCommentParent,'oTalk'=>$oTalk));
|
||||||
|
|
||||||
$this->Viewer_AssignAjax('sCommentId',$oCommentNew->getId());
|
$this->Viewer_AssignAjax('sCommentId',$oCommentNew->getId());
|
||||||
$oTalk->setDateLast(date("Y-m-d H:i:s"));
|
$oTalk->setDateLast(date("Y-m-d H:i:s"));
|
||||||
$oTalk->setUserIdLast($oCommentNew->getUserId());
|
$oTalk->setUserIdLast($oCommentNew->getUserId());
|
||||||
|
|
|
@ -48,6 +48,7 @@
|
||||||
<ul class="topic-info">
|
<ul class="topic-info">
|
||||||
<li class="topic-info-favourite"><a href="#" onclick="return ls.favourite.toggle({$oTalk->getId()},this,'talk');" class="favourite {if $oTalk->getIsFavourite()}active{/if}"></a></li>
|
<li class="topic-info-favourite"><a href="#" onclick="return ls.favourite.toggle({$oTalk->getId()},this,'talk');" class="favourite {if $oTalk->getIsFavourite()}active{/if}"></a></li>
|
||||||
<li class="delete"><a href="{router page='talk'}delete/{$oTalk->getId()}/?security_ls_key={$LIVESTREET_SECURITY_KEY}" onclick="return confirm('{$aLang.talk_inbox_delete_confirm}');" class="delete">{$aLang.delete}</a></li>
|
<li class="delete"><a href="{router page='talk'}delete/{$oTalk->getId()}/?security_ls_key={$LIVESTREET_SECURITY_KEY}" onclick="return confirm('{$aLang.talk_inbox_delete_confirm}');" class="delete">{$aLang.delete}</a></li>
|
||||||
|
{hook run='talk_read_info_item' talk=$oTalk}
|
||||||
</ul>
|
</ul>
|
||||||
</footer>
|
</footer>
|
||||||
</article>
|
</article>
|
||||||
|
|
|
@ -5,6 +5,8 @@
|
||||||
iMaxIdComment=$iMaxIdComment
|
iMaxIdComment=$iMaxIdComment
|
||||||
}
|
}
|
||||||
|
|
||||||
|
{hook run='comment_tree_begin' iTargetId=$iTargetId sTargetType=$sTargetType}
|
||||||
|
|
||||||
<div class="comments" id="comments">
|
<div class="comments" id="comments">
|
||||||
<header class="comments-header">
|
<header class="comments-header">
|
||||||
<h3><span id="count-comments">{$iCountComment}</span> {$iCountComment|declension:$aLang.comment_declension:'russian'}</h3>
|
<h3><span id="count-comments">{$iCountComment}</span> {$iCountComment|declension:$aLang.comment_declension:'russian'}</h3>
|
||||||
|
@ -46,6 +48,7 @@
|
||||||
|
|
||||||
{include file='comment_paging.tpl' aPagingCmt=$aPagingCmt}
|
{include file='comment_paging.tpl' aPagingCmt=$aPagingCmt}
|
||||||
|
|
||||||
|
{hook run='comment_tree_end' iTargetId=$iTargetId sTargetType=$sTargetType}
|
||||||
|
|
||||||
{if $bAllowNewComment}
|
{if $bAllowNewComment}
|
||||||
{$sNoticeNotAllow}
|
{$sNoticeNotAllow}
|
||||||
|
|
|
@ -33,6 +33,7 @@
|
||||||
</li>
|
</li>
|
||||||
<li class="topic-info-favourite" onclick="return ls.favourite.toggle({$oTalk->getId()},$('#fav_topic_{$oTalk->getId()}'),'talk');"><i id="fav_topic_{$oTalk->getId()}" class="favourite {if $oTalk->getIsFavourite()}active{/if}"></i></li>
|
<li class="topic-info-favourite" onclick="return ls.favourite.toggle({$oTalk->getId()},$('#fav_topic_{$oTalk->getId()}'),'talk');"><i id="fav_topic_{$oTalk->getId()}" class="favourite {if $oTalk->getIsFavourite()}active{/if}"></i></li>
|
||||||
<li class="delete"><a href="{router page='talk'}delete/{$oTalk->getId()}/?security_ls_key={$LIVESTREET_SECURITY_KEY}" onclick="return confirm('{$aLang.talk_inbox_delete_confirm}');" class="delete">{$aLang.delete}</a></li>
|
<li class="delete"><a href="{router page='talk'}delete/{$oTalk->getId()}/?security_ls_key={$LIVESTREET_SECURITY_KEY}" onclick="return confirm('{$aLang.talk_inbox_delete_confirm}');" class="delete">{$aLang.delete}</a></li>
|
||||||
|
{hook run='talk_read_info_item' talk=$oTalk}
|
||||||
</ul>
|
</ul>
|
||||||
</footer>
|
</footer>
|
||||||
</article>
|
</article>
|
||||||
|
|
|
@ -5,6 +5,7 @@
|
||||||
iMaxIdComment=$iMaxIdComment
|
iMaxIdComment=$iMaxIdComment
|
||||||
}
|
}
|
||||||
|
|
||||||
|
{hook run='comment_tree_begin' iTargetId=$iTargetId sTargetType=$sTargetType}
|
||||||
|
|
||||||
<div class="comments" id="comments">
|
<div class="comments" id="comments">
|
||||||
<header class="comments-header">
|
<header class="comments-header">
|
||||||
|
@ -48,6 +49,7 @@
|
||||||
|
|
||||||
{include file='comment_paging.tpl' aPagingCmt=$aPagingCmt}
|
{include file='comment_paging.tpl' aPagingCmt=$aPagingCmt}
|
||||||
|
|
||||||
|
{hook run='comment_tree_end' iTargetId=$iTargetId sTargetType=$sTargetType}
|
||||||
|
|
||||||
{if $bAllowNewComment}
|
{if $bAllowNewComment}
|
||||||
{$sNoticeNotAllow}
|
{$sNoticeNotAllow}
|
||||||
|
|
Loading…
Reference in a new issue