add preview on info page
This commit is contained in:
parent
90aa328706
commit
e15c042a79
1 changed files with 15 additions and 0 deletions
|
@ -269,6 +269,21 @@ pandora.ui.documentInfoView = function(data, isMixed) {
|
|||
.appendTo($text);
|
||||
}
|
||||
|
||||
// Preview
|
||||
if (data.extension == 'pdf') {
|
||||
var $div = $('<div>').css({
|
||||
marginTop: '12px',
|
||||
}).html(
|
||||
Ox.range(1, data.dimensions + 1).map(function(page) {
|
||||
return '<a href="/document/'
|
||||
+ data.id + '/' + page
|
||||
+ '"><img src="/documents/'+ data.id + '/128p'+ page + '.jpg"></a>'
|
||||
}).join('\n')
|
||||
)
|
||||
pandora.createLinks($div);
|
||||
$div.appendTo($text)
|
||||
}
|
||||
|
||||
// Referenced --------------------------------------------------------------
|
||||
if (
|
||||
!isMultiple && (
|
||||
|
|
Loading…
Reference in a new issue