add footer to layout

add app name, version, url in footer
This commit is contained in:
Meutel 2014-07-10 10:51:05 +02:00
parent 8e04349ef8
commit 0942319fa8
7 changed files with 6 additions and 4 deletions

View File

@ -27,6 +27,10 @@ app.set('view engine', 'jade');
// load config // load config
_.extend(app.locals, require('./config/'+app.get('env')+'.json')); _.extend(app.locals, require('./config/'+app.get('env')+'.json'));
var appPackage = require('./package.json');
app.locals.appname = appPackage.name;
app.locals.appversion = appPackage.version;
app.locals.appurl = appPackage.url;
// nginx // nginx
app.enable('trust proxy'); app.enable('trust proxy');

View File

@ -38,4 +38,3 @@ block content
ul ul
each author in coauthors each author in coauthors
li: a(href='/author/'+author.id)= author.name li: a(href='/author/'+author.id)= author.name
include footer.jade

View File

@ -44,4 +44,3 @@ block content
div.col-md-7 div.col-md-7
if has_cover == 1 if has_cover == 1
img.img-rounded.img-responsive(src='/calibre/'+path+'/cover.jpg',alt=t('bouquins.book.nocover')) img.img-rounded.img-responsive(src='/calibre/'+path+'/cover.jpg',alt=t('bouquins.book.nocover'))
include footer.jade

View File

@ -1,6 +1,7 @@
footer.footer footer.footer
.container .container
ul.list-inline ul.list-inline
li: a(href=appurl) #{appname} #{appversion}
li: p.text-muted Copyright (c) 2014, Julien Guillot <meutel+github@meutel.net> li: p.text-muted Copyright (c) 2014, Julien Guillot <meutel+github@meutel.net>
li: a(href="/LICENSE.txt") View license li: a(href="/LICENSE.txt") View license
li: a(href="http://calibre-ebook.com/",title="calibre"): img(src="/images/calibre.png") li: a(href="http://calibre-ebook.com/",title="calibre"): img(src="/images/calibre.png")

View File

@ -48,7 +48,6 @@ block content
div.btn-group.center-block div.btn-group.center-block
each p in [10,20,50,100] each p in [10,20,50,100]
button.btn.btn-default.perpage(type="button",value=p)= p button.btn.btn-default.perpage(type="button",value=p)= p
include footer.jade
script script
| $(function() { | $(function() {
| $.i18n.init().done(function() { | $.i18n.init().done(function() {

View File

@ -15,3 +15,4 @@ html(lang=lang)
script(src="/js/home.js") script(src="/js/home.js")
body body
block content block content
include footer.jade

View File

@ -28,4 +28,3 @@ block content
ul ul
each author in authors each author in authors
li: a(href='/author/'+author.id)= author.name li: a(href='/author/'+author.id)= author.name
include footer.jade