Merge branch 'dev'
This commit is contained in:
commit
bb34c41c0d
2 changed files with 13 additions and 4 deletions
|
@ -77,14 +77,18 @@ def generateSubMenu()
|
|||
page=@item
|
||||
end
|
||||
|
||||
if @item[:kind].to_s == "article"
|
||||
if @item[:kind] == :article
|
||||
key=:subtitle
|
||||
else
|
||||
key=:title
|
||||
end
|
||||
|
||||
liste=getSortedChildren(page).collect do |p|
|
||||
link_to_unless_current(p[key]+' <span class="nicer">»</span>',p)
|
||||
if not p[key].nil?
|
||||
link_to_unless_current(p[key]+' <span class="nicer">»</span>',p)
|
||||
else
|
||||
puts 'ERROR: key='+key
|
||||
end
|
||||
end
|
||||
if ! liste.empty? then
|
||||
liste = [ link_to_unless_current(page[key]+' <span class="nicer">»</span>',page) ].concat( liste )
|
||||
|
@ -156,7 +160,11 @@ def brother_for_at(page,n)
|
|||
if i.nil?
|
||||
return nil
|
||||
end
|
||||
brothers[ brothers.index(page) + n ]
|
||||
|
||||
if i + n < 0
|
||||
return nil
|
||||
end
|
||||
brothers[ i + n ]
|
||||
end
|
||||
|
||||
def article_brother(n)
|
||||
|
|
|
@ -7,7 +7,8 @@ if (($#<1)); then
|
|||
exit 1
|
||||
fi
|
||||
|
||||
root="$HOME/Sites/webroot"
|
||||
cd $0:t/..
|
||||
root="$PWD"
|
||||
|
||||
title="$*"
|
||||
|
||||
|
|
Loading…
Reference in a new issue