-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathusers.php
More file actions
77 lines (71 loc) · 2.66 KB
/
Copy pathusers.php
File metadata and controls
77 lines (71 loc) · 2.66 KB
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
<?PHP
include 'header.php';
include 'language.php';
$uname=$_SESSION['uname'];
$admin=$_SESSION['admin'];
$pword=$_SESSION['password'];
$olv=$_SESSION['version'];
?>
<!DOCTYPE html>
<html>
<?php include('header.html');?>
<body class="hold-transition <?PHP echo $skin;?> sidebar-mini">
<div class="wrapper">
<!-- Navigation -->
<?PHP include 'navigation.php';?>
<div class="content-wrapper">
<section class="content-header">
<h1 class="page-header">
<?PHP echo $lang['USERS'];?>
</h1>
</section>
<section class="content">
<div class="row">
<div class="col-md-12">
<div class="box box-solid">
<div class="box-body">
<table class="table table-condensed table-striped" id="jobDataTables">
<thead>
<tr>
<th><?PHP echo $lang['USER_GROUP'];?> </th>
<th><?PHP echo $lang['TOTAL_NUM_JOBS'];?> (<?PHP echo $lang['SLOTS'];?>)</th>
<th><?PHP echo $lang['NUM_PENDING_JOBS'];?> (<?PHP echo $lang['SLOTS'];?>)</th>
<th><?PHP echo $lang['NUM_RUNNING_JOBS'];?> (<?PHP echo $lang['SLOTS'];?>)</th>
<th><?PHP echo $lang['NUM_SUSP_JOBS'];?> (<?PHP echo $lang['SLOTS'];?>)</th>
<th><?PHP echo $lang['NUM_RESERVED_JOB_SLOTS'];?></th>
<th><?PHP echo $lang['MAX_JOB_SLOTS'];?> </th>
<th><?PHP echo $lang['JOB_SLOT_LIMIT_PER_CORE'];?></th>
</tr>
</thead>
<tbody>
<?PHP
$users=shell_exec('source ./env.sh;export OLWD='.$pword.';cmd/runas '.$uname.' cmd/uinfo');
foreach(json_decode($users, true) as $user) {
echo '<tr>';
echo '<td>'.$user['USER'].'</td>';
echo '<td><a href="'.$user['JOB_URL'].'">'.$user['NUM_JOBS'].'</font></a></td>';
echo '<td>'.$user['NUM_PENDING_JOBS'].'</td>';
echo '<td>'.$user['NUM_RUNNING_JOBS'].'</td>';
echo '<td>'.$user['NUM_SUSP_JOBS'].'</td>';
echo '<td>'.$user['NUM_RESERVED_SLOTS'].'</td>';
echo '<td>'.$user['MAX_JOB_SLOTS'].'</td>';
echo '<td>'.$user['MAX_SLOTS_PER_PROCESSOR'].'</td>';
echo '</tr>';
}
?>
</tbody>
</table>
</div>
</div>
</div>
</div>
</section>
</div>
</div>
<?PHP include('js.html');?>
<?PHP
// datatables Initialization
include 'datatablesInit.php';
?>
</body>
</html>