-
Notifications
You must be signed in to change notification settings - Fork 0
/
user-manager.jsp
197 lines (173 loc) · 8.59 KB
/
user-manager.jsp
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
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
<meta charset="utf-8"/>
<link rel="icon" type="image/png" sizes="96x96" href="../assets/images/logo.png">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"/>
<title>Quản lý sản phẩm</title>
<meta content='width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0' name='viewport'/>
<meta name="viewport" content="width=device-width"/>
<!-- Bootstrap core CSS -->
<link href="../assets/css/my-css/admin/bootstrap.min.css" rel="stylesheet"/>
<!-- Animation library for notifications -->
<link href="../assets/css/my-css/admin/animate.min.css" rel="stylesheet"/>
<!-- Paper Dashboard core CSS -->
<link href="../assets/css/my-css/admin/paper-dashboard.css" rel="stylesheet"/>
<!-- Fonts and icons -->
<link href="http://maxcdn.bootstrapcdn.com/font-awesome/latest/css/font-awesome.min.css" rel="stylesheet">
<link href='https://fonts.googleapis.com/css?family=Muli:400,300' rel='stylesheet' type='text/css'>
<%-- Datatable--%>
<link href="https://cdn.datatables.net/v/dt/jqc-1.12.4/dt-2.0.3/datatables.min.css" rel="stylesheet">
<script src="https://cdn.datatables.net/v/dt/jqc-1.12.4/dt-2.0.3/datatables.min.js"></script>
</head>
<body>
<div class="wrapper">
<div class="sidebar" data-background-color="white" data-active-color="primary">
<!--
Tip 1: you can change the color of the sidebar's background using: data-background-color="white | black"
Tip 2: you can change the color of the active button using the data-active-color="primary | info | success | warning | danger"
-->
<div class="sidebar-wrapper">
<div class="logo">
<a href="../home.jsp" class="simple-text">
Máy khoan
</a>
</div>
<ul class="nav">
<li>
<a href="dashboard.jsp">
<i class="ti-panel"></i>
<p>Dashboard</p>
</a>
</li>
<li class="active">
<a href="user-manager.jsp">
<i class="ti-user"></i>
<p>Quản lý người dùng</p>
</a>
</li>
<li>
<a href="products-management.jsp">
<i class="ti-check-box"></i>
<p>Quản lý sản phẩm</p>
</a>
</li>
<li>
<a href="order-management.jsp">
<i class="ti-shopping-cart"></i>
<p>Quản lý đơn hàng</p>
</a>
</li>
</ul>
</div>
</div>
<div class="main-panel">
<nav class="navbar navbar-default">
<div class="container-fluid">
<div class="navbar-header">
<button type="button" class="navbar-toggle">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar bar1"></span>
<span class="icon-bar bar2"></span>
<span class="icon-bar bar3"></span>
</button>
<a class="navbar-brand" href="#">Quản lý người dùng</a>
</div>
<div class="collapse navbar-collapse">
<ul class="nav navbar-nav navbar-right">
<li>
<a href="#" class="dropdown-toggle" data-toggle="dropdown">
<i class="ti-panel"></i>
<p>Stats</p>
</a>
</li>
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown">
<i class="ti-bell"></i>
<p class="notification">5</p>
<p>Notifications</p>
<b class="caret"></b>
</a>
<ul class="dropdown-menu">
<li><a href="#">Notification 1</a></li>
<li><a href="#">Notification 2</a></li>
<li><a href="#">Notification 3</a></li>
<li><a href="#">Notification 4</a></li>
<li><a href="#">Another notification</a></li>
</ul>
</li>
<li>
<a href="#">
<i class="ti-settings"></i>
<p>Settings</p>
</a>
</li>
</ul>
</div>
</div>
</nav>
<div class="content">
<div class="container-fluid">
<div class="row">
<div class="col-md-12">
<div class="card">
<div class="header">
<h4 class="title">Striped Table</h4>
<p class="category">Here is a subtitle for this table</p>
</div>
<div class="content table-responsive table-full-width">
<table id="user-mn" class="table table-striped">
<thead>
<tr>
<th>ID</th>
<th>Tên người dùng</th>
<th>Email</th>
</tr>
</thead>
</table>
<script>
$(document).ready(function (){
var table = $('#user-mn').DataTable({
"ajax" :{
"url":"UserManager",
"dataSrc":"",
},
"columns": [
{"data":"id"},
{"data":"username"},
{"data":"email"},
// {
// "data":null,
// "defaultContent":"<button>Delete</button"
// }
],
});
// $('#users tbody').on('click','button',function (){
// var data = table.row($(this).parents('tr')).data();
// var username = data.username;
//
// $.ajax({
// type: "POST",
// url: "deleteUser",
// data : {username: username},
// success: function (response){
// alert(response);
// table.ajax.reload();
// },
// error: function (xhr,status,error){
// alert("Error: "+error);
// }
// })
// })
})
</script>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</body>
</html>