mirror of
https://git.code.sf.net/p/seeddms/code
synced 2025-05-08 20:46:05 +00:00
initial code for extensions and hooks
This commit is contained in:
parent
a8f3c7be59
commit
17b2e06fe9
11
ext/example/conf.php
Normal file
11
ext/example/conf.php
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
<?php
|
||||||
|
$_GLOBALS['SEEDDMS_EXT']['example'] = array(
|
||||||
|
'title' => 'Example Extension',
|
||||||
|
'description' => 'Example Extension',
|
||||||
|
'version' => '1.0.0',
|
||||||
|
'author' => array('name'=>'Uwe Steinmann', 'email'=>'uwe@steinmann.cx', 'company'=>'MMK GmbH'),
|
||||||
|
'constraints' => array(
|
||||||
|
'depends' => array('php' => '5.4.4-', 'seeddms' => '4.2.0-'),
|
||||||
|
),
|
||||||
|
);
|
||||||
|
?>
|
|
@ -49,6 +49,14 @@ $folder = $document->getFolder();
|
||||||
/* Get the notify list before removing the document */
|
/* Get the notify list before removing the document */
|
||||||
$nl = $document->getNotifyList();
|
$nl = $document->getNotifyList();
|
||||||
$docname = $document->getName();
|
$docname = $document->getName();
|
||||||
|
|
||||||
|
if (is_array($GLOBALS['SEEDDMS_HOOKS']['RemoveDocument'])) {
|
||||||
|
foreach($GLOBALS['SEEDDMS_HOOKS']['RemoveDocument'] as $_classRef) {
|
||||||
|
$_procObj = & new $_classRef;
|
||||||
|
$ret = $_procObj->postRemoveDocument($dms, $document);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (!$document->remove()) {
|
if (!$document->remove()) {
|
||||||
UI::exitError(getMLText("document_title", array("documentname" => getMLText("invalid_doc_id"))),getMLText("error_occured"));
|
UI::exitError(getMLText("document_title", array("documentname" => getMLText("invalid_doc_id"))),getMLText("error_occured"));
|
||||||
} else {
|
} else {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user