|
|
|
|
|
|
|
|
$.getJSON( |
|
|
$.getJSON( |
|
|
conf.openapi + "/documents/" + docid, |
|
|
conf.openapi + "/documents/" + docid, |
|
|
function (doc) { |
|
|
function (doc) { |
|
|
|
|
|
$('.autodoc_document_name.span').html(doc.name); |
|
|
|
|
|
$('.autodoc_document_name.input').val(doc.name); |
|
|
|
|
|
|
|
|
|
|
|
$('.autodoc_document_created').html(doc.created); |
|
|
|
|
|
$('.autodoc_document_languages').html(doc.languages.join(',')); |
|
|
|
|
|
$('.autodoc_document_owner').html(doc.owner); |
|
|
|
|
|
$('.autodoc_document_pages').html(doc.pageId.length); |
|
|
|
|
|
for(var i=0; i<doc.tags.length; i++) { |
|
|
|
|
|
var tag = $('.autodoc_document_tags_template').clone().removeClass('d-none'); |
|
|
|
|
|
$(tag).html(doc.tags[i].name); |
|
|
|
|
|
$(tag).addClass('badge-' + doc.tags[i].color); |
|
|
|
|
|
$('.autodoc_document_tags').append(tag); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
if ($('.slick-slide').length > 0) { |
|
|
if ($('.slick-slide').length > 0) { |
|
|
$('.autodoc_document_carousel').slick('unslick'); |
|
|
$('.autodoc_document_carousel').slick('unslick'); |
|
|
} |
|
|
} |