- 问题:系统用户管理授权栏目只列出最高二级栏目。
- 解决办法:
- 打开
/dede/sys_admin_user_add.php
和/dede/sys_admin_user_edit.php
文件,添加以下函数:function getalltype($reid = 0, $step = '', $typeids = array()) { global $dsql, $result; $dsql->SetQuery("SELECT reid,id,typename FROM `dede_arctype` WHERE reid='$reid' AND (ispart=0 OR ispart=1) ORDER BY sortrank"); $dsql->Execute($reid); if ($dsql->GetTotalRow($reid) > 0) { while ($row = $dsql->GetArray($reid)) { $result .= "<option value='{$row['id']}' class='" . (empty($row['reid']) ? 'b' : 's') . "type'" . (in_array($row['id'], $typeids) ? ' selected' : '') . ">{$step}{$row['typename']}</option>\r\n"; getalltype($row['id'], $step . '—', $typeids); } } return $result; } $typeOptions = getalltype(0, '', $typeids);
- 打开