diff --git a/out/out.DocumentAccess.php b/out/out.DocumentAccess.php index 5619112e2..64de1396f 100644 --- a/out/out.DocumentAccess.php +++ b/out/out.DocumentAccess.php @@ -51,7 +51,7 @@ $tmp = explode('.', basename($_SERVER['SCRIPT_FILENAME'])); $view = UI::factory($theme, $tmp[1], array('dms'=>$dms, 'user'=>$user, 'folder'=>$folder, 'document'=>$document, 'allusers'=>$allUsers, 'allgroups'=>$allGroups)); if($view) { $view->setParam('accessobject', $accessop); - $view->show(); + $view($_GET); exit; } diff --git a/out/out.DocumentNotify.php b/out/out.DocumentNotify.php index d1004cb64..f5931965e 100644 --- a/out/out.DocumentNotify.php +++ b/out/out.DocumentNotify.php @@ -49,7 +49,7 @@ $tmp = explode('.', basename($_SERVER['SCRIPT_FILENAME'])); $view = UI::factory($theme, $tmp[1], array('dms'=>$dms, 'user'=>$user, 'folder'=>$folder, 'document'=>$document, 'sortusersinlist'=>$settings->_sortUsersInList)); if($view) { $view->setParam('accessobject', $accessop); - $view->show(); + $view($_GET); exit; } diff --git a/out/out.MoveDocument.php b/out/out.MoveDocument.php index 1feb063a6..056ce28de 100644 --- a/out/out.MoveDocument.php +++ b/out/out.MoveDocument.php @@ -68,7 +68,7 @@ $tmp = explode('.', basename($_SERVER['SCRIPT_FILENAME'])); $view = UI::factory($theme, $tmp[1], array('dms'=>$dms, 'user'=>$user, 'folder'=>$folder, 'document'=>$document, 'target'=>$target)); if($view) { $view->setParam('accessobject', $accessop); - $view->show(); + $view($_GET); exit; } diff --git a/views/bootstrap/class.DocumentAccess.php b/views/bootstrap/class.DocumentAccess.php index 51f3d9b89..b58478e54 100644 --- a/views/bootstrap/class.DocumentAccess.php +++ b/views/bootstrap/class.DocumentAccess.php @@ -40,23 +40,9 @@ class SeedDMS_View_DocumentAccess extends SeedDMS_Bootstrap_Style { print "\n"; } /* }}} */ - function show() { /* {{{ */ - $dms = $this->params['dms']; - $user = $this->params['user']; - $document = $this->params['document']; - $folder = $this->params['folder']; - $allUsers = $this->params['allusers']; - $allGroups = $this->params['allgroups']; - - - $this->htmlStartPage(getMLText("document_title", array("documentname" => htmlspecialchars($document->getName())))); - $this->globalNavigation($folder); - $this->contentStart(); - $this->pageNavigation($this->getFolderPathHTML($folder, true, $document), "view_document", $document); - + function js() { /* {{{ */ + header('Content-Type: application/json'); ?> - - +$(document).ready( function() { + $('body').on('submit', '#form1', function(ev){ + if(checkForm()) return; + event.preventDefault(); + }); +}); params['dms']; + $user = $this->params['user']; + $document = $this->params['document']; + $folder = $this->params['folder']; + $allUsers = $this->params['allusers']; + $allGroups = $this->params['allgroups']; + + + $this->htmlStartPage(getMLText("document_title", array("documentname" => htmlspecialchars($document->getName())))); + $this->globalNavigation($folder); + $this->contentStart(); + $this->pageNavigation($this->getFolderPathHTML($folder, true, $document), "view_document", $document); $this->contentHeading(getMLText("edit_document_access")); $this->contentContainerStart(); @@ -233,7 +239,7 @@ function checkForm() print "
"; } ?> -
+ diff --git a/views/bootstrap/class.DocumentNotify.php b/views/bootstrap/class.DocumentNotify.php index e6c752fbe..b2191a18e 100644 --- a/views/bootstrap/class.DocumentNotify.php +++ b/views/bootstrap/class.DocumentNotify.php @@ -31,22 +31,9 @@ require_once("class.Bootstrap.php"); */ class SeedDMS_View_DocumentNotify extends SeedDMS_Bootstrap_Style { - function show() { /* {{{ */ - $dms = $this->params['dms']; - $user = $this->params['user']; - $folder = $this->params['folder']; - $document = $this->params['document']; - $sortusersinlist = $this->params['sortusersinlist']; - - $notifyList = $document->getNotifyList(); - - $this->htmlStartPage(getMLText("document_title", array("documentname" => htmlspecialchars($document->getName())))); - $this->globalNavigation($folder); - $this->contentStart(); - $this->pageNavigation($this->getFolderPathHTML($folder, true, $document), "view_document", $document); - + function js() { /* {{{ */ + header('Content-Type: application/json'); ?> - +$(document).ready( function() { + $('body').on('submit', '#form1', function(ev){ + if(checkForm()) return; + event.preventDefault(); + }); +}); params['dms']; + $user = $this->params['user']; + $folder = $this->params['folder']; + $document = $this->params['document']; + $sortusersinlist = $this->params['sortusersinlist']; + + $notifyList = $document->getNotifyList(); + + $this->htmlStartPage(getMLText("document_title", array("documentname" => htmlspecialchars($document->getName())))); + $this->globalNavigation($folder); + $this->contentStart(); + $this->pageNavigation($this->getFolderPathHTML($folder, true, $document), "view_document", $document); + $this->contentHeading(getMLText("edit_existing_notify")); $this->contentContainerStart(); @@ -107,7 +115,7 @@ function checkForm() ?>
- + diff --git a/views/bootstrap/class.MoveDocument.php b/views/bootstrap/class.MoveDocument.php index 576350f21..8b63db8de 100644 --- a/views/bootstrap/class.MoveDocument.php +++ b/views/bootstrap/class.MoveDocument.php @@ -31,6 +31,12 @@ require_once("class.Bootstrap.php"); */ class SeedDMS_View_MoveDocument extends SeedDMS_Bootstrap_Style { + function js() { /* {{{ */ + header('Content-Type: application/json'); + + $this->printFolderChooserJs("form1"); + } /* }}} */ + function show() { /* {{{ */ $dms = $this->params['dms']; $user = $this->params['user']; @@ -50,7 +56,7 @@ class SeedDMS_View_MoveDocument extends SeedDMS_Bootstrap_Style {
- +
:printFolderChooser("form1", M_READWRITE, -1, $target);?>printFolderChooserHtml("form1", M_READWRITE, -1, $target);?>
">