zjk
2026-07-31 8665daa7aa863f96d0d8f27c167edae1efc38022
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
<!doctype html>
<html lang="zh-CN">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>角色 - 访客机自助登记管理平台</title>
  <link rel="stylesheet" href="../css/dashboard.css">
  <link rel="stylesheet" href="../css/components.css">
  <link rel="stylesheet" href="../css/role-management.css">
</head>
<body>
  <div class="app-shell">
    <aside class="sidebar">
      <div class="brand">
        <img src="../assets/login-avatar.svg" alt="">
        <strong>访客机自助登记管理平台</strong>
      </div>
      <nav class="menu" aria-label="主菜单">
        <a class="menu-item" href="./dashboard.html"><span class="menu-icon home"></span><span>首页</span></a>
        <section class="menu-group open">
          <button class="menu-title" type="button"><span class="menu-icon screen"></span><span>系统</span><span class="chevron"></span></button>
          <a href="./system-config.html">系统配置</a>
          <a href="./protocol-config.html">入园承诺</a>
          <a href="./version-update.html">访客机版本更新</a>
        </section>
        <section class="menu-group open">
          <button class="menu-title" type="button"><span class="menu-icon device"></span><span>设备管理</span><span class="chevron"></span></button>
          <a href="./visitor-machine.html">访客机管理</a>
          <a href="./door-management.html">门禁管理</a>
        </section>
        <section class="menu-group open">
          <button class="menu-title" type="button"><span class="menu-icon people"></span><span>人员管理</span><span class="chevron"></span></button>
          <a href="./department-management.html">部门</a>
          <a href="./employee-management.html">员工管理</a>
        </section>
        <a class="menu-item" href="./area-management.html"><span class="menu-icon map"></span><span>区域管理</span></a>
        <section class="menu-group open">
          <button class="menu-title" type="button"><span class="menu-icon log"></span><span>记录与日志</span><span class="chevron"></span></button>
          <a href="./visitor-record.html">访客登记记录</a>
          <a href="./operation-log.html">操作日志</a>
        </section>
        <section class="menu-group open">
          <button class="menu-title" type="button"><span class="menu-icon account"></span><span>账号管理</span><span class="chevron"></span></button>
          <a href="./platform-admin.html">平台管理员</a>
          <a class="active" href="./role-management.html">角色</a>
        </section>
      </nav>
    </aside>
 
    <section class="main">
      <header class="topbar">
        <div></div>
        <div class="top-actions">
          <button class="icon-button" type="button" title="全屏"><span class="expand-icon"></span></button>
          <span class="user-avatar">用</span>
          <div class="user-menu">
            <button id="userMenuButton" class="user-name" type="button" aria-haspopup="true" aria-expanded="false">
              <span id="userDisplayName">用户</span><span class="user-caret"></span>
            </button>
            <div id="userDropdown" class="user-dropdown" hidden>
              <button type="button" data-action="home">返回首页</button>
              <button type="button" data-action="logout">退出登录</button>
            </div>
          </div>
        </div>
      </header>
 
      <div class="tabs">
        <span class="home-tab"></span>
        <span class="tab-divider"></span>
        <span id="pageTab" class="tab active">角色</span>
      </div>
 
      <main class="role-form-page">
        <section class="role-form-card">
          <header class="role-form-header">
            <h1 id="pageTitle">新增角色</h1>
            <button id="backButton" class="role-back" type="button">返回</button>
          </header>
 
          <form id="roleForm" class="role-form">
            <label class="role-field required">
              <span>角色名称</span>
              <input id="roleName" type="text" placeholder="请输入">
            </label>
            <label class="role-field">
              <span>备注</span>
              <input id="roleRemark" type="text" placeholder="请输入">
            </label>
          </form>
 
          <div class="role-divider"></div>
 
          <section class="role-permission-section">
            <h2><span>*</span> 操作权限</h2>
            <div id="detailPermissionTab" class="role-detail-tab" hidden>权限</div>
            <table class="permission-table">
              <thead>
                <tr>
                  <th>板块</th>
                  <th>页面</th>
                  <th>权限</th>
                </tr>
              </thead>
              <tbody id="permissionTableBody"></tbody>
            </table>
            <div id="permissionEmpty" class="role-empty" hidden>暂无权限菜单数据</div>
          </section>
 
          <footer id="formActions" class="role-form-actions">
            <button class="role-reset" type="button" id="cancelButton">取消</button>
            <button class="role-search" type="submit" form="roleForm" id="saveRoleButton">保存</button>
          </footer>
        </section>
      </main>
    </section>
  </div>
 
  <script src="../js/components.js"></script>
  <script src="../js/config.js"></script>
  <script src="../js/role-form.js"></script>
</body>
</html>