Compare commits
3 commits
e4f8ffbf86
...
1d5fdf35ec
| Author | SHA1 | Date | |
|---|---|---|---|
| 1d5fdf35ec | |||
| c5d481ee78 | |||
| 65012d34ee |
6 changed files with 10 additions and 5 deletions
|
|
@ -55,11 +55,11 @@ server {
|
||||||
proxy_buffering off;
|
proxy_buffering off;
|
||||||
proxy_read_timeout 90; #should be in sync with gunicorn timeout
|
proxy_read_timeout 90; #should be in sync with gunicorn timeout
|
||||||
proxy_connect_timeout 90; #should be in sync with gunicorn timeout
|
proxy_connect_timeout 90; #should be in sync with gunicorn timeout
|
||||||
|
client_max_body_size 32m;
|
||||||
if (!-f $request_filename) {
|
if (!-f $request_filename) {
|
||||||
proxy_pass http://127.0.0.1:2620;
|
proxy_pass http://127.0.0.1:2620;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
client_max_body_size 32m;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
error_page 400 /;
|
error_page 400 /;
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
#!/usr/bin/env python
|
#!/usr/bin/env python3
|
||||||
import os
|
import os
|
||||||
import signal
|
import signal
|
||||||
import sys
|
import sys
|
||||||
|
|
|
||||||
|
|
@ -66,7 +66,7 @@ pandora.ui.document = function() {
|
||||||
? pandora.user.ui.documents[item.id].position
|
? pandora.user.ui.documents[item.id].position
|
||||||
: 1,
|
: 1,
|
||||||
url: '/documents/' + item.id + '/'
|
url: '/documents/' + item.id + '/'
|
||||||
+ item.title.replace('?', '_') + '.' + item.extension,
|
+ pandora.safePDFName(item.title + '.' + item.extension),
|
||||||
width: that.width(),
|
width: that.width(),
|
||||||
zoom: 'fit'
|
zoom: 'fit'
|
||||||
})
|
})
|
||||||
|
|
|
||||||
|
|
@ -196,7 +196,7 @@ pandora.ui.documentDialog = function(options) {
|
||||||
? pandora.user.ui.documents[item.id].position
|
? pandora.user.ui.documents[item.id].position
|
||||||
: 1,
|
: 1,
|
||||||
url: '/documents/' + item.id + '/'
|
url: '/documents/' + item.id + '/'
|
||||||
+ item.title.replace('?', '_') + '.' + item.extension,
|
+ pandora.safePDFName(item.title + '.' + item.extension),
|
||||||
width: dialogWidth,
|
width: dialogWidth,
|
||||||
zoom: 'fit'
|
zoom: 'fit'
|
||||||
})
|
})
|
||||||
|
|
|
||||||
|
|
@ -2625,6 +2625,11 @@ pandora.openURL = function(url) {
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
pandora.safePDFName = function(name) {
|
||||||
|
name = name.replace('?', '_').replace('#', '_');
|
||||||
|
return name;
|
||||||
|
};
|
||||||
|
|
||||||
pandora.saveURL = function(url, name) {
|
pandora.saveURL = function(url, name) {
|
||||||
var link = document.createElement('a');
|
var link = document.createElement('a');
|
||||||
if (typeof link.download === 'string') {
|
if (typeof link.download === 'string') {
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
#!/usr/bin/env python
|
#!/usr/bin/env python3
|
||||||
from __future__ import print_function
|
from __future__ import print_function
|
||||||
import json
|
import json
|
||||||
import os
|
import os
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue