Add a template variable to tell if the Topic is viewed standalone by URL, or not.
This commit is contained in:
parent
ea31d52ac0
commit
db839e2dc4
4 changed files with 11 additions and 1 deletions
|
|
@ -172,6 +172,7 @@ sub viewTemplateVariables {
|
|||
$var->{topStoryCreationDate} = $topStory->get('creationDate');
|
||||
##TODO: Photo variables
|
||||
}
|
||||
$var->{standAlone} = $self->{_standAlone};
|
||||
|
||||
return $var;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -19,6 +19,7 @@ our $HELP = {
|
|||
],
|
||||
fields => [],
|
||||
variables => [
|
||||
{ name => 'standAlone' },
|
||||
{ name => 'story_loop',
|
||||
variables => [
|
||||
{ name => 'url' },
|
||||
|
|
|
|||
|
|
@ -99,6 +99,12 @@ our $I18N = {
|
|||
lastUpdated => 0,
|
||||
},
|
||||
|
||||
'standAlone' => {
|
||||
message => q|This variable will be true if the Story Topic is being viewed directly, by its URL. Otherwise, if it is viewed as part of a Page Layout or other Container, it will be false.|,
|
||||
context => q|Template variable.|,
|
||||
lastUpdated => 0,
|
||||
},
|
||||
|
||||
'view template' => {
|
||||
message => q|View Story Topic Template|,
|
||||
context => q|Template variable.|,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue