use new method printClickDocumentJs()

This commit is contained in:
Uwe Steinmann 2019-11-25 09:51:39 +01:00
parent 24f030f1c7
commit 5e9a4515b3
4 changed files with 13 additions and 5 deletions

View File

@ -41,6 +41,7 @@ class SeedDMS_View_ApprovalSummary extends SeedDMS_Bootstrap_Style {
parent::jsTranslations(array('cancel', 'splash_move_document', 'confirm_move_document', 'move_document', 'confirm_transfer_link_document', 'transfer_content', 'link_document', 'splash_move_folder', 'confirm_move_folder', 'move_folder')); parent::jsTranslations(array('cancel', 'splash_move_document', 'confirm_move_document', 'move_document', 'confirm_transfer_link_document', 'transfer_content', 'link_document', 'splash_move_folder', 'confirm_move_folder', 'move_folder'));
$this->printDeleteDocumentButtonJs(); $this->printDeleteDocumentButtonJs();
$this->printClickDocumentJs();
} /* }}} */ } /* }}} */
function show() { /* {{{ */ function show() { /* {{{ */

View File

@ -41,6 +41,7 @@ class SeedDMS_View_ReviewSummary extends SeedDMS_Bootstrap_Style {
parent::jsTranslations(array('cancel', 'splash_move_document', 'confirm_move_document', 'move_document', 'confirm_transfer_link_document', 'transfer_content', 'link_document', 'splash_move_folder', 'confirm_move_folder', 'move_folder')); parent::jsTranslations(array('cancel', 'splash_move_document', 'confirm_move_document', 'move_document', 'confirm_transfer_link_document', 'transfer_content', 'link_document', 'splash_move_folder', 'confirm_move_folder', 'move_folder'));
$this->printDeleteDocumentButtonJs(); $this->printDeleteDocumentButtonJs();
$this->printClickDocumentJs();
} /* }}} */ } /* }}} */
function show() { /* {{{ */ function show() { /* {{{ */

View File

@ -189,11 +189,9 @@ $('body').on('click', '[id^=\"table-row-folder\"] td:nth-child(2)', function(ev)
scrollTop: 200 scrollTop: 200
}, 200); }, 200);
}); });
/* catch click on a document row in the list folders and documents */ <?php
$('body').on('click', '[id^=\"table-row-document\"] td:nth-child(2)', function(ev) { $this->printClickDocumentJs();
attr_id = $(ev.currentTarget).parent().attr('id').split('-')[3]; ?>
window.location = '../out/out.ViewDocument.php?documentid=' + attr_id;
});
$('body').on('click', '.order-btn', function(ev) { $('body').on('click', '.order-btn', function(ev) {
ev.preventDefault(); ev.preventDefault();
var element = $(this); var element = $(this);

View File

@ -36,6 +36,14 @@ require_once("SeedDMS/Preview.php");
*/ */
class SeedDMS_View_WorkflowSummary extends SeedDMS_Bootstrap_Style { class SeedDMS_View_WorkflowSummary extends SeedDMS_Bootstrap_Style {
function js() { /* {{{ */
header('Content-Type: application/javascript; charset=UTF-8');
parent::jsTranslations(array('cancel', 'splash_move_document', 'confirm_move_document', 'move_document', 'confirm_transfer_link_document', 'transfer_content', 'link_document', 'splash_move_folder', 'confirm_move_folder', 'move_folder'));
$this->printDeleteDocumentButtonJs();
$this->printClickDocumentJs();
} /* }}} */
function show() { /* {{{ */ function show() { /* {{{ */
$dms = $this->params['dms']; $dms = $this->params['dms'];
$user = $this->params['user']; $user = $this->params['user'];