Get("Site_Path"); $admin = $objConfig->Get("AdminDirectory"); if(!strlen($admin)) $admin = "admin"; $localURL=$rootURL."kernel/"; $adminURL = $rootURL.$admin; $imagesURL = $adminURL."/images"; //$pathtolocal = $pathtoroot."in-news/"; require_once ($pathtoroot.$admin."/include/elements.php"); require_once ($pathtoroot."kernel/admin/include/navmenu.php"); //require_once ($pathtolocal."admin/include/navmenu.php"); require_once($pathtoroot.$admin."/toolbar.php"); require_once($pathtoroot.$admin."/listview/listview.php"); $m = GetModuleArray(); foreach($m as $key=>$value) { $path = $pathtoroot. $value."admin/include/parser.php"; if(file_exists($path)) { include_once($path); } } unset($objEditItems); $objEditItems = new clsUserManager(); $objEditItems->SourceTable = $objSession->GetEditTable("PortalUser"); $objEditItems->EnablePaging = FALSE; //Multiedit init $en = (int)$_GET["en"]; $objEditItems->Query_Item("SELECT * FROM ".$objEditItems->SourceTable); $itemcount=$objEditItems->NumItems(); $c = $objEditItems->GetItemByIndex($en); if($itemcount>1) { if ($en+1 == $itemcount) $en_next = -1; else $en_next = $en+1; if ($en == 0) $en_prev = -1; else $en_prev = $en-1; } $action = "m_user_sysperm"; $envar = "env=" . BuildEnv() . "&en=$en"; $section = 'in-portal:edituser_permission'; $PermModule = $_GET["module"]; $title = prompt_language("la_Text_Editing")." ".prompt_language("la_Text_User")." '".$c->Get("Login")."' - ".prompt_language("la_tab_Permissions"); //$formaction = $adminURL."/user/adduser_custom.php?".$envar; //Display header $sec = $objSections->GetSection($section); $objCatToolBar = new clsToolBar(); $objCatToolBar->Add("img_save", "la_Save","#","swap('img_save','toolbar/tool_select_f2.gif');", "swap('img_save', 'toolbar/tool_select.gif');","edit_submit('edituser','UserEditStatus','".$admin."/users/adduser_permissions.php',0);","tool_select.gif"); $objCatToolBar->Add("img_cancel", "la_Cancel","#","swap('img_cancel','toolbar/tool_cancel_f2.gif');", "swap('img_cancel', 'toolbar/tool_cancel.gif');","edit_submit('edituser','UserEditStatus','".$admin."/users/adduser_permissions.php',-1);","tool_cancel.gif"); if ( isset($en_prev) || isset($en_next) ) { $url = $RootUrl.$admin."/users/user_addpermission.php"; $StatusField = "UserEditStatus"; $form = "edituser"; MultiEditButtons($objCatToolBar,$en_next,$en_prev,$form,$StatusField,$url,$sec->Get("OnClick"),'&module='.$_REQUEST['module'],'la_PrevUser','la_NextUser'); } //echo "
"; print_r($objCatToolBar); echo "
"; int_header($objCatToolBar,NULL,$title); ?>
".prompt_language("la_prompt_Description")."\n"; ?> GetPersonalGroup(); $UserGroupExists = is_object($UserGroup); $permlist = array(); $ado = &GetADODBConnection(); $sql = "SELECT * FROM ".GetTablePrefix()."PermissionConfig AS pc LEFT JOIN ".GetTablePrefix()."Phrase AS p ON pc.Description = p.Phrase WHERE pc.ModuleId='$PermModule' AND p.LanguageId = ".$objSession->Get("Language")." ORDER BY p.Translation ASC"; if($objSession->HasSystemPermission("DEBUG.LIST")) echo htmlentities($sql,ENT_NOQUOTES)."
\n"; $rs = $ado->Execute($sql); while($rs && !$rs->EOF) { $desc = $rs->fields["Description"]; $Permission = $rs->fields["PermissionName"]; echo ""; echo ""; $checked = ""; if($UserGroupExists) { //echo "GroupPermission on $Permission: ".$UserGroup->HasSystemPermission($Permission)."
"; //echo "UserPermission on $Permission: ".$c->HasSystemPermission($Permission)."
"; $Inherit = ($UserGroup->HasSystemPermission($Permission)==-1); } else { $Inherit =TRUE; } if($Inherit) { $checked = " CHECKED"; $value = $c->HasSystemPermission($Permission); } else $value = $UserGroup->HasSystemPermission($Permission); echo " \n"; $checked = ""; $imgsrc="red"; if($value==1) { $checked = " CHECKED"; $imgsrc = "green"; $current = "true"; } else { $imgsrc = "red"; $current = "false"; } $disabled = ""; if($Inherit) { $InheritValue = $current; $UnInheritValue = "false"; $disabled = "DISABLED=\"true\""; } else { $disabled = ""; $InheritValue = ($Value==1); $UnInheritValue = ($Value !=1); } echo " "; $permlist[]=$Permission; $rs->MoveNext(); } ?>
".prompt_language("la_ColHeader_PermInherited")."".prompt_language("la_ColHeader_PermAccess")."
"; echo prompt_language($desc).""; echo " "; echo "
"> ">
>
" name="viewmenu">