$mod->setVersion("3.1.90"); $mod->setRevision('$Rev$'); $mod->setDescription(_T("Password Policy", "ppolicy")); $mod->setAPIVersion("0:1:0"); $mod->setPriority(600); /* Get the base module instance reference */ $base =& $MMCApp->getModule('base'); /* Get the users sub-module instance reference */ $users =& $base->getSubmod('users'); /* Add the page to the module */ $page = new Page("indexppolicy", _T("Password policies", "ppolicy")); $page->setImg("modules/base/graph/access/img/icn_global_active.gif", "modules/base/graph/access/img/icn_global.gif"); $page->setFile("modules/ppolicy/default/index.php"); $users->addPage($page); $page = new Page("addppolicy", _T("Add a password policy", "ppolicy")); $page->setImg("modules/base/graph/access/img/icn_global_active.gif", "modules/base/graph/access/img/icn_global.gif"); $page->setFile("modules/ppolicy/default/add.php"); $users->addPage($page); $page = new Page("editppolicy", _T("Edit a password policy", "ppolicy")); $page->setFile("modules/ppolicy/default/edit.php"); $page->setOptions(array("visible" => False)); $users->addPage($page); $page = new Page("deleteppolicy", _T("Delete a password policy", "ppolicy")); $page->setFile("modules/ppolicy/default/delete.php", array("noHeader" => True, "visible" => False)); $users->addPage($page); $page = new Page("ajaxPPoliciesFilter"); $page->setFile("modules/ppolicy/default/ajaxPPoliciesFilter.php", array("AJAX" => True, "visible" => False)); $users->addPage($page); /* Declare variable to will can set hiden it */ $ppolicyattr = getPPolicyAttributesKeys(); foreach ($ppolicyattr as $key => $info) {
$submod->addPage($page); $page = new Page("delete", _T("Delete a computer", "samba")); $page->setOptions(array("noHeader" => True, "visible" => False)); $submod->addPage($page); $mod->addSubmod($submod); /** * Config submod */ $submod = new SubModule("config"); $submod->setDefaultPage("samba/config/index"); $submod->setImg('modules/samba/graph/navbar/pref'); $submod->setDescription(_T("Configuration"), "samba"); $submod->setVisibility(False); $submod->setAlias('shares'); $page = new Page("index", _T("SAMBA configuration", "samba")); $page->setImg("modules/samba/graph/img/config/icn_global_active.gif", "modules/samba/graph/img/config/icn_global.gif"); $submod->addPage($page); $page = new Page("restart", _T("restart SAMBA service", "samba")); $page->setOptions(array("visible" => False)); $submod->addPage($page); $page = new Page("reload", _T("Reload SAMBA service", "samba")); $page->setOptions(array("visible" => False)); $submod->addPage($page); $mod->addSubmod($submod); /** * Declare ACL */ $mod->addACL("isSamba", _T("Add/delete SAMBA's attributes", "samba")); $mod->addACL("isSmbDesactive", _T("Enable/Disable account", "samba")); $mod->addACL("isSmbLocked", _T("Lock/Unlock account", "samba")); $mod->addACL("hasProfile", _T("Network profile", "samba"));
* (at your option) any later version. * * MMC is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with MMC. If not, see <http://www.gnu.org/licenses/>. */ /** * module declaration */ $mod = new Module("bulkimport"); $mod->setVersion("2.5.95"); $mod->setRevision('$Rev$'); $mod->setDescription(_T("Bulk user manager via CSV files", "bulkimport")); $mod->setAPIVersion('0:0:0'); /* Get the base module instance reference */ $base =& $MMCApp->getModule('base'); /* Get the computers sub-module instance reference */ $users =& $base->getSubmod('users'); /* Add the page to the module */ $page = new Page("bulkimport", _T("Bulk import (CSV)", "bulkimport")); $page->setFile("modules/bulkimport/import/index.php"); $page->setImg("modules/base/graph/users/img/icn_addUser_active.gif", "modules/base/graph/users/img/icn_addUser.gif"); $users->addPage($page); $MMCApp =& MMCApp::getInstance(); $MMCApp->addModule($mod); unset($page); unset($users);
function _createSamba4ConfigSubmodule($isProvisioned) { $submodule = new SubModule("config"); $submodule->setDefaultPage("samba4/config/index"); $submodule->setImg('modules/samba4/graph/navbar/pref'); $submodule->setDescription(_T("Configuration"), "samba4"); $submodule->setVisibility(False); $submodule->setAlias('shares'); $page = new Page("index", _T("SAMBA4 configuration", "samba4")); $page->setImg("modules/samba4/graph/img/config/icn_global_active.gif", "modules/samba4/graph/img/config/icn_global.gif"); $submodule->addPage($page); $page = new Page("restart", _T("restart SAMBA service", "samba4")); $page->setOptions(array("visible" => False)); $submodule->addPage($page); $page = new Page("reload", _T("Reload SAMBA service", "samba4")); $page->setOptions(array("visible" => False)); $submodule->addPage($page); return $submodule; }