hjg
2024-10-30 8cf23534166c07e711aac2a25911ada317ba01f0
提交 | 用户 | 时间
58d006 1 <?xml version="1.0" encoding="UTF-8"?>
A 2 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
3 <html xmlns="http://www.w3.org/1999/xhtml"
4 xmlns:c="http://java.sun.com/jsp/jstl/core"
5 xmlns:h="http://java.sun.com/jsf/html"
6 xmlns:f="http://java.sun.com/jsf/core"
7 xmlns:ui="http://java.sun.com/jsf/facelets">
8 <ui:composition template="/template/nit/tmp_brief.xhtml">
9     <ui:define name="acss">
10         <style>
11         #searchBtn {
12             height: 34px;
13         }
14         p.error {
15             color: #D9534F
16         }
17         select.error, input.error {
18             border: 1px solid #D9534F;
19         }
20         i.fa.danger {
21             color: #D15B47
22         }
23         i.fa.success {
24             color: #87B87F
25         }
26         #simple-table th,#simple-table td{
27             text-align: center;
28             padding: 2px 8px;
29         }
30         .bigger-95{
31         font-size: 95% !important;
32         }
33         .btn-xs, .btn-group-xs > .btn{
34           padding-top: 0px;
35           padding-bottom: 0px;
36         }
37         #form .control-label {
38             margin-right: -14px
39         }
40         .t-error{
41             color: red;
42             position: relative;
43             right: 2px;
44             top: 3px;
45         }
46         </style>
47     </ui:define>
48     <ui:define name="acontent">
49         <div class="row main-content">
50             <div class="col-md-12 main-content-header">
51                 <div class="row">
52                     <div class="col-md-12 form-horizontal">
53                         <div class="col-md-6">
54                             <div class="input-group">
55                                 <input type="text" class="form-control" placeholder="请输入登录名"
56                                     aria-describedby="basic-addon2" data-bind="value:filter" /> <a
57                                     href="javascript:;" id="searcha" class="input-group-addon"><span
58                                     class="fa fa-search"></span></a>
59                             </div>
60                         </div>
61                         <div class="col-md-4">
62                             <select class="form-control"
63                                 data-bind="value:role,options:roles,optionsText:'name',optionsValue:'id',event:{change:change}"></select>
64                         </div>
65                         <div class="col-md-2">
66                             <button id="ctbtn" type="button" class="btn btn-primary"
67                                 autocomplete="off">新建</button>
68                         </div>
69                     </div>
70                 </div>
71             </div>
72
73
74             <table
75                 class="table table-striped table-bordered table-condensed table-hover">
76                 <thead>
77                     <tr>
78                         <th>序号</th>
79                         <th>登陆名</th>
80                         <th>email</th>
81                         <th>所属角色</th>
82                         <th>用户验证</th>
83                         <th>是否有效</th>
84                         <th>登录次数</th>
85                         <th>最后登录</th>
86                         <th>操作</th>
87                     </tr>
88                 </thead>
89                 <tbody data-bind="foreach:users">
90                     <tr>
91                         <td data-bind="text:$index()+1">序号</td>
92                         <td data-bind="text:$data.username">登陆名</td>
93                         <td data-bind="text:$data.email">email</td>
94                         <td
95                             data-bindd="text:(($data.role()==null)?'':($data.role().name()))">所属角色</td>
96                         <td data-bind="text:$data.certify==true?'是':'否'">用户验证</td>
97                         <td><a href="javascrpt:;" data-bind="click:$parent.valid"><span
98                                 data-bind="css:$data.valid()==true?'fa fa-check':'fa fa-times' "></span></a></td>
99                         <th data-bind="text:$data.logins">登录次数</th>
100                         <th data-bind="text:$data.lastlogin">最后登录</th>
101                         <td><a href="javascript:void(0);"
102                             data-bind="click:$parent.rm" title="删除"><span
103                                 class="fa fa-times"></span></a>| <a href="javascript:void(0);"
104                             data-bind="click:$parent.edit" title="编辑"><span
105                                 class="fa fa-edit"></span></a>| <a href="javascript:void(0);"
106                             data-bind="click:$parent.rstpwd" title="密码重置"><span
107                                 class="fa fa-gift"></span></a></td>
108                     </tr>
109                 </tbody>
110                 <tfoot>
111                     <tr>
112                         <td colspan="9">
113                             <div id="pagdiv"></div>
114                         </td>
115                     </tr>
116                 </tfoot>
117             </table>
118         </div>
119         <input type="hidden" value="#{jrole.role!=null?jrole.role.id:0}"
120             id="roleid" />
121         <input type="hidden" value="#{param.tid==null?0:param.tid}" id="tid" />
122
123         <div class="modal fade" id="modal1" tabindex="-1" role="dialog"
124             aria-labelledby="myModalLabel" aria-hidden="true">
125             <div class="modal-dialog">
126                 <div class="modal-content">
127                     <div class="modal-header">
128                         <button type="button" class="close" data-dismiss="modal"
129                             aria-label="Close">
130                             <span aria-hidden="true">&times;</span>
131                         </button>
132                         <h4 class="modal-title"  data-bind="text:edittitle" ></h4>
133                     </div>
134                     <div class="modal-body">
135                         <form class="form-horizontal" id="fm1">
136                             <input type="hidden" name="id" id="id" value=""
137                                 data-bind="value:user().id" />
138                             <div class="form-group">
139                                 <label for="username" class="col-sm-2 control-label">用户名</label>
140                                 <div class="col-sm-8">
141                                     <input type="text" class="form-control" id="username"
142                                         name="username" placeholder="username"
143                                         data-bind="value:user().username" />
144                                 </div>
145                             </div>
146                             <div class="form-group">
147                                 <label for="description" class="col-sm-2 control-label">email</label>
148                                 <div class="col-sm-8">
149                                     <input type="text" class="form-control" id="email" name="email"
150                                         placeholder="请输入电子邮箱 !" data-bind="value:user().email" />
151                                 </div>
152                             </div>
153                             <div class="form-group">
154                                 <label for="TARGET" class="col-sm-2 control-label">角色</label>
155                                 <div class="col-sm-8">
156                                     <select
157                                         data-bind="value:role1,options:roles,optionsText:'name',optionsValue:'id'">
158                                     </select>
159                                 </div>
160                             </div>
161                         </form>
162                     </div>
163                     <div id="errmsg"></div>
164                     <div class="modal-footer">
165                         <button type="button" class="btn btn-primary"
166                             data-loading-text="保存中..." id="tjbtn">提交</button>
167                     </div>
168                 </div>
169             </div>
170         </div>
171     </ui:define>
172     <ui:define name="myscript">
173         <script type="text/javascript" src="#{request.contextPath}/system/js/users.js"></script>
174     </ui:define>
175 </ui:composition>
176 </html>