mirror of
https://git.code.sf.net/p/seeddms/code
synced 2025-02-11 09:35:00 +00:00
add legacy access rights for groups
This commit is contained in:
parent
83e42948ee
commit
7d9de047bd
|
@ -406,7 +406,7 @@ class SeedDMS_AccessOperation {
|
|||
return false;
|
||||
} /* }}} */
|
||||
|
||||
protected function check_view_lecacy_access($view, $get=array()) { /* {{{ */
|
||||
protected function check_view_legacy_access($view, $get=array()) { /* {{{ */
|
||||
if($this->user->isAdmin())
|
||||
return true;
|
||||
|
||||
|
@ -419,86 +419,100 @@ class SeedDMS_AccessOperation {
|
|||
} else {
|
||||
return false;
|
||||
}
|
||||
if(array_intersect($scripts, array(
|
||||
'AddDocument',
|
||||
'AddEvent',
|
||||
'AddFile',
|
||||
'AddSubFolder',
|
||||
'AddToTransmittal',
|
||||
'ApprovalSummary',
|
||||
'ApproveDocument',
|
||||
'Calendar',
|
||||
'CategoryChooser',
|
||||
'ChangePassword',
|
||||
'CheckInDocument',
|
||||
'Clipboard',
|
||||
'DocumentAccess',
|
||||
'DocumentChooser',
|
||||
'DocumentNotify',
|
||||
'DocumentVersionDetail',
|
||||
'DropFolderChooser',
|
||||
'EditAttributes',
|
||||
'EditComment',
|
||||
'EditDocumentFile',
|
||||
'EditDocument',
|
||||
'EditEvent',
|
||||
'EditFolder',
|
||||
'EditOnline',
|
||||
'EditUserData',
|
||||
'ErrorDlg',
|
||||
'FolderAccess',
|
||||
'FolderChooser',
|
||||
'FolderNotify',
|
||||
'ForcePasswordChange',
|
||||
'GroupView',
|
||||
'Help',
|
||||
'KeywordChooser',
|
||||
'Login',
|
||||
'ManageNotify',
|
||||
'MoveDocument',
|
||||
'MoveFolder',
|
||||
'MyAccount',
|
||||
'MyDocuments',
|
||||
'OpensearchDesc',
|
||||
'OverrideContentStatus',
|
||||
'PasswordForgotten',
|
||||
'PasswordSend',
|
||||
'ReceiptDocument',
|
||||
'ReceiptSummary',
|
||||
'RemoveDocumentFile',
|
||||
'RemoveDocument',
|
||||
'RemoveEvent',
|
||||
'RemoveFolderFiles',
|
||||
'RemoveFolder',
|
||||
'RemoveTransmittal',
|
||||
'RemoveVersion',
|
||||
'RemoveWorkflowFromDocument',
|
||||
'ReturnFromSubWorkflow',
|
||||
'ReviewDocument',
|
||||
'ReviewSummary',
|
||||
'ReviseDocument',
|
||||
'RewindWorkflow',
|
||||
'RunSubWorkflow',
|
||||
'SearchForm',
|
||||
'Search',
|
||||
'Session',
|
||||
'SetExpires',
|
||||
'SetRecipients',
|
||||
'SetReviewersApprovers',
|
||||
'SetRevisors',
|
||||
'SetWorkflow',
|
||||
'SubstituteUser',
|
||||
'TransmittalMgr',
|
||||
'TriggerWorkflow',
|
||||
'UpdateDocument',
|
||||
'UserDefaultKeywords',
|
||||
'UserImage',
|
||||
'UsrView',
|
||||
'ViewDocument',
|
||||
'ViewEvent',
|
||||
'ViewFolder',
|
||||
'WorkflowGraph',
|
||||
'WorkflowSummary')))
|
||||
|
||||
if($this->user->isGuest()) {
|
||||
$user_allowed = array(
|
||||
'Calendar',
|
||||
'ErrorDlg',
|
||||
'Help',
|
||||
'Login',
|
||||
'Search',
|
||||
'ViewDocument',
|
||||
'ViewFolder',
|
||||
);
|
||||
} else {
|
||||
$user_allowed = array(
|
||||
'AddDocument',
|
||||
'AddEvent',
|
||||
'AddFile',
|
||||
'AddSubFolder',
|
||||
'AddToTransmittal',
|
||||
'ApprovalSummary',
|
||||
'ApproveDocument',
|
||||
'Calendar',
|
||||
'CategoryChooser',
|
||||
'ChangePassword',
|
||||
'CheckInDocument',
|
||||
'Clipboard',
|
||||
'DocumentAccess',
|
||||
'DocumentChooser',
|
||||
'DocumentNotify',
|
||||
'DocumentVersionDetail',
|
||||
'DropFolderChooser',
|
||||
'EditAttributes',
|
||||
'EditComment',
|
||||
'EditDocumentFile',
|
||||
'EditDocument',
|
||||
'EditEvent',
|
||||
'EditFolder',
|
||||
'EditOnline',
|
||||
'EditUserData',
|
||||
'ErrorDlg',
|
||||
'FolderAccess',
|
||||
'FolderChooser',
|
||||
'FolderNotify',
|
||||
'ForcePasswordChange',
|
||||
'GroupView',
|
||||
'Help',
|
||||
'KeywordChooser',
|
||||
'Login',
|
||||
'ManageNotify',
|
||||
'MoveDocument',
|
||||
'MoveFolder',
|
||||
'MyAccount',
|
||||
'MyDocuments',
|
||||
'OpensearchDesc',
|
||||
'OverrideContentStatus',
|
||||
'PasswordForgotten',
|
||||
'PasswordSend',
|
||||
'ReceiptDocument',
|
||||
'ReceiptSummary',
|
||||
'RemoveDocumentFile',
|
||||
'RemoveDocument',
|
||||
'RemoveEvent',
|
||||
'RemoveFolderFiles',
|
||||
'RemoveFolder',
|
||||
'RemoveTransmittal',
|
||||
'RemoveVersion',
|
||||
'RemoveWorkflowFromDocument',
|
||||
'ReturnFromSubWorkflow',
|
||||
'ReviewDocument',
|
||||
'ReviewSummary',
|
||||
'ReviseDocument',
|
||||
'RewindWorkflow',
|
||||
'RunSubWorkflow',
|
||||
'Search',
|
||||
'Session',
|
||||
'SetExpires',
|
||||
'SetRecipients',
|
||||
'SetReviewersApprovers',
|
||||
'SetRevisors',
|
||||
'SetWorkflow',
|
||||
'SubstituteUser',
|
||||
'TransmittalMgr',
|
||||
'TriggerWorkflow',
|
||||
'UpdateDocument',
|
||||
'UserDefaultKeywords',
|
||||
'UserImage',
|
||||
'UsrView',
|
||||
'ViewDocument',
|
||||
'ViewEvent',
|
||||
'ViewFolder',
|
||||
'WorkflowGraph',
|
||||
'WorkflowSummary');
|
||||
}
|
||||
|
||||
if(array_intersect($scripts, $user_allowed))
|
||||
return true;
|
||||
|
||||
return false;
|
||||
|
@ -524,7 +538,7 @@ class SeedDMS_AccessOperation {
|
|||
*/
|
||||
function check_view_access($view, $get=array()) { /* {{{ */
|
||||
if(!$this->settings->_advancedAcl) {
|
||||
return $this->check_view_lecacy_access($view, $get);
|
||||
return $this->check_view_legacy_access($view, $get);
|
||||
}
|
||||
if(is_string($view)) {
|
||||
$scripts = array($view);
|
||||
|
|
Loading…
Reference in New Issue
Block a user