Merge branch 'develop' of https://github.com/nicolargo/glances into develop

This commit is contained in:
nicolargo 2018-06-09 10:26:15 +02:00
commit 3cc7174dc9
4 changed files with 2301 additions and 1556 deletions

View File

@ -22,10 +22,32 @@ export default function GlancesPluginProcesslistController($scope, GlancesStats,
for (var i = 0; i < processlistStats.length; i++) {
var process = processlistStats[i];
process.memvirt = process.memory_info[1];
process.memres = process.memory_info[0];
process.timeplus = $filter('timedelta')(process.cpu_times);
process.timemillis = $filter('timemillis')(process.cpu_times);
process.memvirt = "?";
process.memres = "?";
if (process.memory_info) {
process.memvirt = process.memory_info[1];
process.memres = process.memory_info[0];
}
process.timeplus = "?";
process.timemillis = "?";
if (process.cpu_times) {
process.timeplus = $filter('timedelta')(process.cpu_times);
process.timemillis = $filter('timemillis')(process.cpu_times);
}
if (process.num_threads === null) {
process.num_threads = -1;
}
if (process.cpu_percent === null) {
process.cpu_percent = -1;
}
if (process.memory_percent === null) {
process.memory_percent = -1;
}
process.ioRead = null;
process.ioWrite = null;

View File

@ -17,19 +17,19 @@
</div>
<div class="table-row"
ng-repeat="process in vm.processes | orderBy:vm.sorter.column:vm.sorter.isReverseColumn(vm.sorter.column) | limitTo: vm.getLimit() track by process.pid">
<div class="table-cell" ng-class="vm.getCpuPercentAlert(process)">{{process.cpu_percent | number:1}}</div>
<div class="table-cell" ng-class="vm.getMemoryPercentAlert(process)">{{process.memory_percent | number:1}}
</div>
<div class="table-cell" ng-class="vm.getCpuPercentAlert(process)">{{ process.cpu_percent == -1 ? '?' : (process.cpu_percent | number:1) }}</div>
<div class="table-cell" ng-class="vm.getMemoryPercentAlert(process)">{{ process.memory_percent == -1 ? '?' : (process.memory_percent | number:1) }}</div>
<div class="table-cell hidden-xs hidden-sm">{{process.memvirt | bytes}}</div>
<div class="table-cell hidden-xs hidden-sm">{{process.memres | bytes}}</div>
<div class="table-cell">{{process.pid}}</div>
<div class="table-cell text-left">{{process.username}}</div>
<div class="table-cell hidden-xs hidden-sm">
<div class="table-cell hidden-xs hidden-sm" ng-if="process.timeplus != '?'">
<span ng-show="process.timeplus.hours > 0" class="highlight">{{ process.timeplus.hours }}h</span>{{
process.timeplus.minutes | leftPad:2:'0' }}:{{ process.timeplus.seconds | leftPad:2:'0' }}<span
ng-show="process.timeplus.hours <= 0">.{{ process.timeplus.milliseconds | leftPad:2:'0' }}</span>
</div>
<div class="table-cell text-left hidden-xs hidden-sm">{{process.num_threads}}</div>
<div class="table-cell hidden-xs hidden-sm" ng-if="process.timeplus == '?'">?</div>
<div class="table-cell text-left hidden-xs hidden-sm">{{ process.num_threads == -1 ? '?' : process.num_threads }}</div>
<div class="table-cell" ng-class="{nice: process.isNice}">{{process.nice | exclamation}}</div>
<div class="table-cell" ng-class="{status: process.status == 'R'}">{{process.status}}</div>
<div class="table-cell hidden-xs hidden-sm" ng-show="vm.ioReadWritePresent">{{process.ioRead}}</div>

File diff suppressed because it is too large Load Diff

File diff suppressed because one or more lines are too long