-
Notifications
You must be signed in to change notification settings - Fork 0
/
sidebar.php
283 lines (192 loc) · 7.85 KB
/
sidebar.php
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
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
<style>
#dd{
margin:10%;
width:100%;
justify-content:center;
}
.sidebar{
margin-bottom: -100%; /* any large number will do */
padding-bottom: 100%;
}
</style>
<?php
include('db_connect.php');
$usr = $conn->query("SELECT Max(id) as m FROM users");
while($row = $usr->fetch_assoc()):
?>
<?php endwhile; ?>
<script src="pj/assets/js/vendor.min.js"></script>
<script src="pj/assets/js/app.min.js"></script>
<body id="page-top">
<!-- Page Wrapper -->
<div id="">
<ul class="navbar-nav bg-gradient-primary sidebar sidebar-dark nav-treeview" id="accordionSidebar">
<br>
<!-- Sidebar - Brand -->
<a class="sidebar-brand d-flex align-items-center justify-content-center" href="">
<img src="ME-logo-white.png" id="dd" />
<br>
</a>
<script>
</script>
<!-- Divider -->
<!-- Nav Item - Dashboard -->
<li class="nav-item active">
<a class="nav-link" href="./index.php?page=home">
<i class="fas fa-fw fa-tachometer-alt"></i>
<span>Tableau de bord</span></a>
</li>
<!-- Heading -->
<?php if($_SESSION['login_type'] == 1): ?>
<script>
if ($(window).width() < 700 || $(window).height() < 700) {
document.getElementById("accordionSidebar").classList.add('toggled');
document.getElementById("accordionSidebar").classList.remove('nav-treeview');
}
</script>
<div class="sidebar-heading">
Client
</div>
<?php
$mail = $_SESSION['login_id'];
$li = '';
$spo = $conn->query("SELECT MAX(id) as id FROM users");
while($row=$spo->fetch_assoc()):
?>
<!-- Nav Item - Pages Collapse Menu -->
<li class="nav-item" >
<a class="nav-link nav-new_user tree-item collapsed " href="./index.php?page=new_user&id=<?php echo $row['id'] + 1 ?>">
<i class="fas fa-fw fa-user-plus"></i>
<span>Ajouter Client</span>
</a>
</li>
<?php endwhile; ?>
<!-- Nav Item - Utilities Collapse Menu -->
<li class="nav-item">
<a class="nav-link collapsed" href="./index.php?page=user_list" data-target="#collapseUtilities"
aria-expanded="true" aria-controls="collapseUtilities">
<i class="fas fa-fw fa-users"></i>
<span>Liste Client</span>
</a>
</li>
<!-- Divider -->
<hr class="sidebar-divider">
<!-- Heading -->
<!-- Nav Item - Tables -->
<!-- Heading -->
<div class="sidebar-heading">
Rapports
</div>
<!-- Nav Item - Tables -->
<li class="nav-item">
<a class="nav-link" href="./index.php?page=nps&selected=0">
<i class="fas fa-fw fa-atom"></i>
<span>NPS</span></a>
</li>
<li class="nav-item">
<a class="nav-link" href="./index.php?page=ces&selected=0">
<i class="fas fa-fw fa-stroopwafel"></i>
<span>CES</span></a>
</li>
<li class="nav-item">
<a class="nav-link" href="./index.php?page=csat&selected=0">
<i class="fas fa-fw fa-meteor"></i>
<span>CSAT</span></a>
</li>
<li class="nav-item">
<a class="nav-link" href="./index.php?page=cess&selected=0">
<i class="fas fa-fw fa-meteor"></i>
<span>E-CES</span></a>
</li>
<li class="nav-item">
<a class="nav-link" href="./index.php?page=enps&selected=0">
<i class="fas fa-fw fa-meteor"></i>
<span>E-NPS</span></a>
</li>
<hr class="sidebar-divider">
<div class="sidebar-heading">
</div>
<!-- Nav Item - Tables -->
<li class="nav-item">
<a class="nav-link" href="./index.php?page=supmess">
<i class="fas fa-fw fa-atom"></i>
<span>Message</span></a>
</li>
<hr class="sidebar-divider">
<li class="nav-item">
<a class="nav-link" href="documentation/doc-Admin.php" target="_blank">
<i class="fas fa-fw fa-atom"></i>
<span>Documentation</span></a>
</li>
</ul>
<?php else: ?>
<body id="page-top">
<!-- Page Wrapper -->
<script>
if ($(window).width() < 700 || $(window).height() < 700) {
document.getElementById("accordionSidebar").classList.add('toggled');
document.getElementById("accordionSidebar").classList.remove('nav-treeview');
}
</script>
<hr class="sidebar-divider">
<!-- Heading -->
<div class="sidebar-heading">
Questionnaire
</div>
<!-- Nav Item - Tables -->
<li class="nav-item">
<a class="nav-link" href="./index.php?page=survey_widget">
<i class="fas fa-fw fa-table"></i>
<span>Questionnaire</span></a>
</li>
<hr class="sidebar-divider">
<!-- Heading -->
<div class="sidebar-heading">
Rapport
</div>
<?php
$mail = $_SESSION['login_id'];
$link = '';
$spey = $conn->query("SELECT s.title FROM survey_set AS s, users as u WHERE FIND_IN_SET(s.title,u.serv) and u.id = '".$mail."' ");
while($row=$spey->fetch_assoc()):
?>
<!-- Nav Item - Tables -->
<li class="nav-item">
<a class="nav-link" href="./index.php?page=<?php echo strtolower($row['title'])."_user"?>">
<i class="fas fa-fw fa-meteor"></i>
<span><?php echo $row['title'] ?></span></a>
</li>
<?php endwhile; ?>
<hr class="sidebar-divider">
<li class="nav-item">
<a class="nav-link" href="./index.php?page=messages">
<i class="fas fa-fw fa-atom"></i>
<span>Messages</span>
</a>
</li>
<hr class="sidebar-divider">
<li class="nav-item">
<a class="nav-link" href="./index.php?page=sup">
<i class="fas fa-fw fa-life-ring"></i>
<span>Support</span>
</a>
</li>
<hr class="sidebar-divider">
<li class="nav-item">
<a class="nav-link" href="documentation/Doc-clients.php" target="_blank">
<i class="fas fa-fw fa-atom"></i>
<span>Documentation</span></a>
</li>
</div>
<!--
<div class="text-center d-none d-md-inline">
<button class="rounded-circle border-0" id="sidebarToggle"></button>
Sidebar Message -->
</ul>
<!-- End of Sidebar -->
<?php endif; ?>
<!-- Custom scripts for all pages-->
<script src="vendor/jquery/jquery.min.js"></script>
<script src="vendor/bootstrap/js/bootstrap.bundle.min.js"></script>
<!-- Core plugin JavaScript-->
<script src="vendor/jquery-easing/jquery.easing.min.js"></script>