国内流行的内容管理系统(CMS)多端全媒体解决方案 https://www.dedebiz.com
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

101 lines
4.2KB

  1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  2. <html xmlns="http://www.w3.org/1999/xhtml">
  3. <head>
  4. <meta http-equiv="Content-Type" content="text/html; charset=<?php echo $cfg_soft_lang; ?>">
  5. <title>组权限设置</title>
  6. <link rel="stylesheet" href="../static/web/css/bootstrap.min.css">
  7. <link rel="stylesheet" href="../static/web/font/css/font-awesome.min.css">
  8. <link rel="stylesheet" href="../static/web/css/admin.css">
  9. <style>label{margin: 5px 3px;}</style>
  10. </head>
  11. <body>
  12. <table width="98%" cellpadding="2" cellspacing="1" align="center" class="table maintable mt-3 mb-3">
  13. <form name='form1' action='sys_group_add.php' method='post'>
  14. <input type='hidden' name='dopost' value='save'>
  15. <tr>
  16. <td height="26" background="../static/web/img/tbg.gif" align="left" style="padding-left:10px"><a href='sys_group.php'>系统用户组管理</a> &gt; 增加用户组</td>
  17. </tr>
  18. <tr>
  19. <td align="center">
  20. <table width="98%" cellspacing="0" cellpadding="0" class="table table-borderless">
  21. <tr>
  22. <td width="9%" height="26">组名称:</td>
  23. <td width="91%" style="text-align:left"> <input name="groupname" type="text" id="groupname">
  24. </td>
  25. </tr>
  26. <tr>
  27. <td width="9%" height="26">级别值:</td>
  28. <td width="91%" style="text-align:left"> <input name="rankid" type="text" id="rankid" size="6">
  29. (数字,系统已占用的级别值:
  30. <?php
  31. $dsql->SetQuery("Select `rank` From `#@__admintype`");
  32. $dsql->Execute();
  33. while($row = $dsql->GetObject()) echo '<span style=\'color:#e74d58\'>'.$row->rank.'</span>';
  34. ?>
  35. ,级别值必须小于10,超过或等于10所有权限设置将无效(超级管理员),如果10个组不能完全满足您的要求,允许使用小数)</td>
  36. </tr>
  37. <?php
  38. $start = 0;
  39. $k = 0;
  40. $gouplists = file(dirname(__FILE__).'/../inc/grouplist.txt');
  41. foreach($gouplists as $line)
  42. {
  43. $line = trim($line);
  44. if($line=="") continue;
  45. if(preg_match("#^>>#", $line))
  46. {
  47. if($start>0) echo "</td></tr>";
  48. $start++;
  49. $lhead = "
  50. <tr>
  51. <td height='26' colspan='2' bgcolor='#F9FAF3' style='text-align:left;line-height:22px'>{$start}、".str_replace('>>','',$line)."</td></tr>
  52. <tr><td height='26' colspan='2' style='text-align:left;line-height:22px'>
  53. ";
  54. echo $lhead;
  55. }
  56. else if(preg_match("#^>#", $line))
  57. {
  58. $ls = explode('>',$line);
  59. $tag = $ls[1];
  60. $tagname = str_replace('[br]', '<br>', $ls[2]);
  61. if(!preg_match("#<br \/>#", $tagname) ) $tagname .= "<span>($tag)</span>";
  62. else $tagname = str_replace('<br>', "<span>($tag)</span><br>", $tagname);
  63. echo " <label><input name='purviews[]' type='checkbox' class='np' id='purviews$k' value='$tag'> $tagname</label>";
  64. $k++;
  65. }
  66. }
  67. $start++;
  68. ?>
  69. </td>
  70. </tr>
  71. <tr>
  72. <td height='26' colspan='2' bgcolor='#F9FAF3' style="text-align:left"><?php echo $start?>、插件权限</td>
  73. </tr>
  74. <tr>
  75. <td height='26' colspan='2' style='text-align:left'>
  76. <?php
  77. $l = 0;
  78. $dsql->SetQuery('Select plusname From #@__plus');
  79. $dsql->Execute();
  80. while($row=$dsql->GetObject()){
  81. echo " <label><input name='purviews[]' type='checkbox' class='np' id='purviews$k' value='plus_{$row->plusname}'> {$row->plusname}</label>";
  82. $k++;
  83. $l++;
  84. if($l%6==0) echo "<br>";
  85. }
  86. ?>
  87. </td>
  88. </tr>
  89. <tr>
  90. <td colspan="2" align="center" class="py-3">
  91. <button type="submit" class="btn btn-success btn-sm" onClick="DoSubmit('gettag')" class="coolbg np">保存</button>
  92. </td>
  93. </tr>
  94. </table>
  95. </td>
  96. </tr>
  97. </form>
  98. </table>
  99. </body>
  100. </html>