handle download menu entry
This commit is contained in:
parent
6bce40ad3a
commit
515a6d23f6
2 changed files with 3 additions and 1 deletions
|
@ -71,7 +71,7 @@ def run():
|
||||||
(r'/(.*?)/pdf/', FileHandler),
|
(r'/(.*?)/pdf/', FileHandler),
|
||||||
(r'/(.*?)/txt/', FileHandler),
|
(r'/(.*?)/txt/', FileHandler),
|
||||||
(r'/(.*?)/get/', FileHandler, {
|
(r'/(.*?)/get/', FileHandler, {
|
||||||
'download': True
|
'attachment': True
|
||||||
}),
|
}),
|
||||||
(r'/(.*)/(cover|preview)(\d*).jpg', IconHandler),
|
(r'/(.*)/(cover|preview)(\d*).jpg', IconHandler),
|
||||||
(r'/api/', oxtornado.ApiHandler, dict(context=db.session)),
|
(r'/api/', oxtornado.ApiHandler, dict(context=db.session)),
|
||||||
|
|
|
@ -464,6 +464,8 @@ oml.ui.mainMenu = function() {
|
||||||
(oml.$ui.titlesDialog || (
|
(oml.$ui.titlesDialog || (
|
||||||
oml.$ui.titlesDialog = oml.ui.titlesDialog()
|
oml.$ui.titlesDialog = oml.ui.titlesDialog()
|
||||||
)).open();
|
)).open();
|
||||||
|
} else if (id == 'download') {
|
||||||
|
document.location.href = '/' + oml.user.ui.item + '/get/';
|
||||||
} else {
|
} else {
|
||||||
Ox.print('MAIN MENU DOES NOT YET HANDLE', id);
|
Ox.print('MAIN MENU DOES NOT YET HANDLE', id);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue