mirror of
https://github.com/Oreolek/ifhub.club.git
synced 2024-07-01 05:55:02 +03:00
fix Issue #156
This commit is contained in:
parent
eb267b5f4b
commit
76ff03a21b
|
@ -359,6 +359,14 @@ class ModuleTopic_EntityTopic extends Entity {
|
|||
return Router::GetPath('blog').$this->getBlog()->getUrl().'/'.$this->getId().'.html';
|
||||
}
|
||||
}
|
||||
/**
|
||||
* Возвращает полный URL до страницы редактировани топика
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getUrlEdit() {
|
||||
return Router::GetPath($this->getType()).'edit/'.$this->getId().'/';
|
||||
}
|
||||
/**
|
||||
* Возвращает объект голосования за топик текущим пользователем
|
||||
*
|
||||
|
|
|
@ -38,7 +38,7 @@
|
|||
|
||||
<ul class="actions">
|
||||
{if $oUserCurrent and ($oUserCurrent->getId()==$oTopic->getUserId() or $oUserCurrent->isAdministrator() or $oBlog->getUserIsAdministrator() or $oBlog->getUserIsModerator() or $oBlog->getOwnerId()==$oUserCurrent->getId())}
|
||||
<li><a href="{cfg name='path.root.web'}/{$oTopic->getType()}/edit/{$oTopic->getId()}/" title="{$aLang.topic_edit}" class="actions-edit">{$aLang.topic_edit}</a></li>
|
||||
<li><a href="{$oTopic->getUrlEdit()}" title="{$aLang.topic_edit}" class="actions-edit">{$aLang.topic_edit}</a></li>
|
||||
{/if}
|
||||
|
||||
{if $oUserCurrent and ($oUserCurrent->isAdministrator() or $oBlog->getUserIsAdministrator() or $oBlog->getOwnerId()==$oUserCurrent->getId())}
|
||||
|
|
|
@ -32,7 +32,7 @@
|
|||
{if $oUserCurrent and ($oUserCurrent->getId()==$oTopic->getUserId() or $oUserCurrent->isAdministrator() or $oBlog->getUserIsAdministrator() or $oBlog->getUserIsModerator() or $oBlog->getOwnerId()==$oUserCurrent->getId())}
|
||||
<ul class="topic-actions">
|
||||
{if $oUserCurrent and ($oUserCurrent->getId()==$oTopic->getUserId() or $oUserCurrent->isAdministrator() or $oBlog->getUserIsAdministrator() or $oBlog->getUserIsModerator() or $oBlog->getOwnerId()==$oUserCurrent->getId())}
|
||||
<li class="edit"><i class="icon-synio-actions-edit"></i><a href="{cfg name='path.root.web'}/{$oTopic->getType()}/edit/{$oTopic->getId()}/" title="{$aLang.topic_edit}" class="actions-edit">{$aLang.topic_edit}</a></li>
|
||||
<li class="edit"><i class="icon-synio-actions-edit"></i><a href="{$oTopic->getUrlEdit()}" title="{$aLang.topic_edit}" class="actions-edit">{$aLang.topic_edit}</a></li>
|
||||
{/if}
|
||||
|
||||
{if $oUserCurrent and ($oUserCurrent->isAdministrator() or $oBlog->getUserIsAdministrator() or $oBlog->getOwnerId()==$oUserCurrent->getId())}
|
||||
|
|
Loading…
Reference in a new issue