mirror of
https://git.code.sf.net/p/seeddms/code
synced 2025-05-31 05:57:34 +00:00
call hook userMenuItems()
This commit is contained in:
parent
d59e7c1228
commit
c982a23a32
|
@ -261,8 +261,18 @@ $(document).ready(function () {
|
|||
echo " <a href=\"#\" class=\"dropdown-toggle\" data-toggle=\"dropdown\">".($this->params['session']->getSu() ? getMLText("switched_to") : getMLText("signed_in_as"))." '".htmlspecialchars($this->params['user']->getFullName())."' <i class=\"icon-caret-down\"></i></a>\n";
|
||||
echo " <ul class=\"dropdown-menu\" role=\"menu\">\n";
|
||||
if (!$this->params['user']->isGuest()) {
|
||||
echo " <li><a href=\"../out/out.MyDocuments.php?inProcess=1\">".getMLText("my_documents")."</a></li>\n";
|
||||
echo " <li><a href=\"../out/out.MyAccount.php\">".getMLText("my_account")."</a></li>\n";
|
||||
$menuitems = array();
|
||||
$menuitems['my_documents'] = array('link'=>"../out/out.MyDocuments.php?inProcess=1", 'label'=>'my_documents');
|
||||
$menuitems['my_account'] = array('link'=>"../out/out.MyAccount.php", 'label'=>'my_account');
|
||||
$hookObjs = $this->getHookObjects('SeedDMS_View_Bootstrap');
|
||||
foreach($hookObjs as $hookObj) {
|
||||
if (method_exists($hookObj, 'userMenuItems')) {
|
||||
$menuitems = $hookObj->userMenuItems($this, $menuitems);
|
||||
}
|
||||
}
|
||||
foreach($menuitems as $menuitem) {
|
||||
echo "<li><a href=\"".$menuitem['link']."\">".getMLText($menuitem['label'])."</a></li>";
|
||||
}
|
||||
echo " <li class=\"divider\"></li>\n";
|
||||
}
|
||||
$showdivider = false;
|
||||
|
|
Loading…
Reference in New Issue
Block a user