KTCorePlugin.php
10.1 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
<?php
require_once(KT_LIB_DIR . '/plugins/pluginregistry.inc.php');
require_once(KT_LIB_DIR . '/plugins/plugin.inc.php');
class KTCorePlugin extends KTPlugin {
var $bAlwaysInclude = true;
var $sNamespace = "ktcore.plugin";
function setup() {
$this->registerAction('documentaction', 'KTDocumentDetailsAction', 'ktcore.actions.document.displaydetails', 'KTDocumentActions.php');
$this->registerAction('documentaction', 'KTDocumentViewAction', 'ktcore.actions.document.view', 'KTDocumentActions.php');
$this->registerAction('documentaction', 'KTDocumentCheckOutAction', 'ktcore.actions.document.checkout', 'KTDocumentActions.php');
$this->registerAction('documentaction', 'KTDocumentCancelCheckOutAction', 'ktcore.actions.document.cancelcheckout', 'KTDocumentActions.php');
$this->registerAction('documentaction', 'KTDocumentCheckInAction', 'ktcore.actions.document.checkin', 'KTDocumentActions.php');
$this->registerAction('documentaction', 'KTDocumentEditAction', 'ktcore.actions.document.edit', 'KTDocumentActions.php');
$this->registerAction('documentaction', 'KTDocumentDeleteAction', 'ktcore.actions.document.delete', 'KTDocumentActions.php');
$this->registerAction('documentaction', 'KTDocumentMoveAction', 'ktcore.actions.document.move', 'KTDocumentActions.php');
$this->registerAction('documentaction', 'KTDocumentCopyAction', 'ktcore.actions.document.copy', 'KTDocumentActions.php');
$this->registerAction('documentaction', 'KTDocumentRenameAction', 'ktcore.actions.document.rename', 'document/Rename.php');
$this->registerAction('documentaction', 'KTDocumentTransactionHistoryAction', 'ktcore.actions.document.transactionhistory', 'KTDocumentActions.php');
$this->registerAction('documentaction', 'KTDocumentVersionHistoryAction', 'ktcore.actions.document.versionhistory', 'KTDocumentActions.php');
$this->registerAction('documentaction', 'KTDocumentArchiveAction', 'ktcore.actions.document.archive', 'KTDocumentActions.php');
$this->registerAction('documentaction', 'KTDocumentWorkflowAction', 'ktcore.actions.document.workflow', 'KTDocumentActions.php');
$this->registerAction('folderaction', 'KTFolderAddDocumentAction', 'ktcore.actions.folder.addDocument', 'folder/addDocument.php');
$this->registerAction('folderaction', 'KTFolderAddFolderAction', 'ktcore.actions.folder.addFolder', 'KTFolderActions.php');
$this->registerAction('folderaction', 'KTFolderRenameAction', 'ktcore.actions.folder.rename', 'folder/Rename.php');
$this->registerAction('folderaction', 'KTFolderPermissionsAction', 'ktcore.actions.folder.permissions', 'KTFolderActions.php');
$this->registerAction('folderaction', 'KTBulkImportFolderAction', 'ktcore.actions.folder.bulkImport', 'folder/BulkImport.php');
$this->registerAction('folderaction', 'KTBulkUploadFolderAction', 'ktcore.actions.folder.bulkUpload', 'folder/BulkUpload.php');
// Permissions
$this->registerAction('documentaction', 'KTDocumentPermissionsAction', 'ktcore.actions.document.permissions', 'KTPermissions.php');
$this->registerAction('folderaction', 'KTRoleAllocationPlugin', 'ktcore.actions.folder.roles', 'KTPermissions.php');
$this->registerDashlet('KTBeta1InfoDashlet', 'ktcore.dashlet.beta1info', 'KTDashlets.php');
$this->registerDashlet('KTNotificationDashlet', 'ktcore.dashlet.notifications', 'KTDashlets.php');
$this->registerDashlet('KTCheckoutDashlet', 'ktcore.dashlet.checkout', 'KTDashlets.php');
$this->registerAdminPage('authentication', 'KTAuthenticationAdminPage', 'principals', _('Authentication'), _('By default, KnowledgeTree controls its own users and groups and stores all information about them inside the database. In many situations, an organisation will already have a list of users and groups, and needs to use that existing information to allow access to the DMS. These <strong>Authentication Sources</strong> allow the system administrator to specify additional sources of authentication data.'), 'authentication/authenticationadminpage.inc.php');
$this->registeri18n('knowledgeTree', KT_DIR . '/i18n');
$this->registerPortlet(array('browse'),
'KTAdminModePortlet', 'ktcore.portlets.admin_mode',
'KTPortlets.php');
$this->registerPortlet(array('browse', 'dashboard'),
'KTSearchPortlet', 'ktcore.portlets.search',
'KTPortlets.php');
$this->registerPortlet(array('browse'),
'KTBrowseModePortlet', 'ktcore.portlets.browsemodes',
'KTPortlets.php');
$this->registerPortlet(array('administration'),
'KTAdminSectionNavigation', 'ktcore.portlets.adminnavigation',
'KTPortlets.php');
$this->setupAdmin();
}
function setupAdmin() {
// set up the categories.
$this->registerAdminCategory("principals", _("Users and Groups"),
_("Control which users can log in, and are part of which groups and organisational units, from these management panels."));
$this->registerAdminCategory("security", _("Security Management"),
_("Assign permissions to users and groups, and specify which permissions are required to interact with various parts of the Document Management System."));
//$this->registerAdminCategory("plugins", _("Plugin Management"),
// _("Control which plugins are loaded, register new plugins and configure individual plugins."));
$this->registerAdminCategory("storage", _("Document Storage"),
_("Manage checked-out, archived and deleted documents."));
$this->registerAdminCategory("documents", _("Document Metadata and Workflow Configuration"),
_("Configure the document metadata: Document Types, Document Fieldsets, Link Types and Workflows."));
$this->registerAdminCategory("misc", _("Miscellaneous"),
_("Various settings which do not fit into the other categories, including managing help and saved searches."));
// users and groups
$this->registerAdminPage("users", 'KTUserAdminDispatcher', "principals",
_("Manage Users"), _("Add or remove users from the system."),
'admin/userManagement.php', null);
$this->registerAdminPage("groups", 'KTGroupAdminDispatcher', "principals",
_("Manage Groups"), _("Add or remove groups from the system."),
'admin/groupManagement.php', null);
$this->registerAdminPage("units", 'KTUnitAdminDispatcher', "principals",
_("Control Units"), _("Specify which organisational units are available within the repository."),
'admin/unitManagement.php', null);
// security
$this->registerAdminPage("permissions", 'ManagePermissionsDispatcher', "security",
_("Permissions"), _("Create or delete permissions."), 'admin/managePermissions.php', null);
$this->registerAdminPage("roles", 'RoleAdminDispatcher', "security",
_("Roles"), _("Create or delete roles"),
'admin/roleManagement.php', null);
$this->registerAdminPage("conditions", 'KTConditionDispatcher', "security",
_("Dynamic Conditions"),
_("Manage criteria which determine whether a user is permitted to perform a system action."),
'admin/conditions.php', null);
// documents
$this->registerAdminPage("typemanagement", 'KTDocumentTypeDispatcher', 'documents',
_('Document Types'),
_('Manage the different classes of document which can be added to the system.'),
'admin/documentTypes.php', null);
$this->registerAdminPage("fieldmanagement", 'KTDocumentFieldDispatcher', 'documents',
_('Document Fieldsets'),
_('Manage the different types of information that can be associated with classes of documents.'),
'admin/documentFields.php', null);
$this->registerAdminPage("linkmanagement", 'KTDocLinkAdminDispatcher', 'documents',
_('Link Type Management'),
_('Manage the different ways documents can be associated with one another.'),
'admin/documentLinks.php', null);
$this->registerAdminPage("workflows", 'KTWorkflowDispatcher', 'documents',
_('Workflows'), _('Configure the process documents go through.'),
'admin/workflows.php', null);
// storage
$this->registerAdminPage("checkout", 'KTCheckoutAdminDispatcher', 'storage',
_('Checked Out Document Control'),
_('Override the checked-out status of documents if a user has failed to do so.'),
'admin/documentCheckout.php', null);
$this->registerAdminPage("archived", 'ArchivedDocumentsDispatcher', 'storage',
_('Archived Document Restoration'), _("Restore old (archived) documents, usually at a user's request."),
'admin/archivedDocuments.php', null);
$this->registerAdminPage("expunge", 'DeletedDocumentsDispatcher', 'storage',
_('Restore or Expunge Deleted Documents'), _('Restore previously deleted documents, or permanently expunge them.'),
'admin/deletedDocuments.php', null);
// misc
$this->registerAdminPage("helpmanagement", 'ManageHelpDispatcher', 'misc',
_('Edit Help files'), _('Change the help files that are displayed to users.'),
'admin/manageHelp.php', null);
$this->registerAdminPage("savedsearch", 'KTSavedSearchDispatcher', 'misc',
_('Saved searches'),
_('Manage saved searches - searches available by default to all users.'),
'admin/savedSearch.php', null);
$this->registerAdminPage("plugins", 'KTPluginDispatcher', 'misc',
_('Manage plugins'), _('Register new plugins, disable plugins, and so forth'),
'admin/plugins.php', null);
// plugins
}
}
$oRegistry =& KTPluginRegistry::getSingleton();
$oRegistry->registerPlugin('KTCorePlugin', 'ktcore.plugin', __FILE__);
require_once('KTPortlets.php');
require_once(KT_LIB_DIR . '/storage/ondiskpathstoragemanager.inc.php');