mirror of
https://github.com/Oreolek/ifhub.club.git
synced 2024-06-26 03:30:48 +03:00
Мелкие исправления
This commit is contained in:
parent
42c0af725d
commit
1eb8f4812d
|
@ -11,11 +11,11 @@
|
|||
|
||||
{* Получатели *}
|
||||
{component 'user' template='choose'
|
||||
items = ($recepient) ? [[ 'text' => $recepient->getLogin(), 'value' => $recepient->getId() ]] : null
|
||||
selectedValue = ($recepient) ? $recepient->getId() : null
|
||||
form = ($_aRequest['talk_recepient_id']) ? null : $_aRequest
|
||||
items = ($recepient) ? [[ 'text' => $recepient->getLogin(), 'value' => $recepient->getId() ]] : false
|
||||
selectedValue = ($recepient) ? $recepient->getId() : false
|
||||
form = ($_aRequest['talk_recepient_id']) ? false : $_aRequest
|
||||
name = 'talk_users[]'
|
||||
rules = [ 'required' => true, 'rangetags' => '[1,99]' ]
|
||||
rules = [ 'required' => true ]
|
||||
classes = 'js-talk-add-user-choose'
|
||||
label = {lang 'talk.add.fields.users.label'}
|
||||
lang_choose = {lang 'talk.add.choose_friends'}}
|
||||
|
|
|
@ -5,22 +5,16 @@
|
|||
* @param boolean $isPreview
|
||||
*}
|
||||
|
||||
{$type = $smarty.local.type}
|
||||
{component_define_params params=[ 'topic', 'type', 'blogs', 'blogId', 'skipBlogs', 'mods', 'classes', 'attributes' ]}
|
||||
|
||||
{$typeCode = $type->getCode()}
|
||||
|
||||
{if $LS->Topic_IsAllowTopicType( $typeCode )}
|
||||
{$template = $LS->Component_GetTemplatePath('topic', "topic-add-type-{$typeCode}" )}
|
||||
{if $LS->Topic_IsAllowTopicType($typeCode)}
|
||||
{$template = $LS->Component_GetTemplatePath('topic', "topic-add-type-{$typeCode}")}
|
||||
|
||||
{* Если для указанного типа существует шаблон, то подключаем его *}
|
||||
{* Иначе подключаем дефолтный шаблон топика *}
|
||||
{if ! $template}
|
||||
{$template = $LS->Component_GetTemplatePath('topic', 'add')}
|
||||
{if $template}
|
||||
{component "topic.topic-add-type-$typeCode" params=$params}
|
||||
{else}
|
||||
{component 'topic.add' params=$params}
|
||||
{/if}
|
||||
|
||||
{include "$template"
|
||||
topic=$smarty.local.topic
|
||||
type=$smarty.local.type
|
||||
blogs=$smarty.local.blogs
|
||||
blogId=$smarty.local.blogId
|
||||
skipBlogs=$smarty.local.skipBlogs }
|
||||
{/if}
|
|
@ -5,17 +5,16 @@
|
|||
* @param boolean $isPreview
|
||||
*}
|
||||
|
||||
{$topic = $smarty.local.topic}
|
||||
{component_define_params params=[ 'topic', 'isPreview', 'isList', 'mods', 'classes', 'attributes' ]}
|
||||
|
||||
{$type = $topic->getType()}
|
||||
|
||||
{if $LS->Topic_IsAllowTopicType( $type )}
|
||||
{$template = $LS->Component_GetTemplatePath('topic', "topic-type-{$type}" )}
|
||||
{if $LS->Topic_IsAllowTopicType($type)}
|
||||
{$template = $LS->Component_GetTemplatePath('topic', "topic-type-{$type}")}
|
||||
|
||||
{* Если для указанного типа существует шаблон, то подключаем его *}
|
||||
{* Иначе подключаем дефолтный шаблон топика *}
|
||||
{if ! $template}
|
||||
{$template = $LS->Component_GetTemplatePath('topic', 'topic')}
|
||||
{if $template}
|
||||
{component "topic.topic-type-$type" params=$params}
|
||||
{else}
|
||||
{component 'topic' params=$params}
|
||||
{/if}
|
||||
|
||||
{include "$template" topic=$topic isList=$smarty.local.isList isPreview=$smarty.local.isPreview}
|
||||
{/if}
|
|
@ -1 +1 @@
|
|||
Subproject commit 90265e4bcb27ef33eea7b2192cd978750f6fb00d
|
||||
Subproject commit 8410a744b062f67347e67b1fff81e29b0a4bbff3
|
Loading…
Reference in a new issue