hide speed chart when disable auto refresh

This commit is contained in:
MaysWind 2016-12-04 23:36:12 +08:00
parent 4c277d4204
commit 864372f2e9
4 changed files with 4 additions and 2 deletions

View file

@ -232,7 +232,7 @@
<span>&nbsp;</span>
<div class="pull-right">
<div class="pull-right ng-cloak" ng-if="globalStatusContext.isEnabled">
<a class="global-status" ng-pop-chart ng-data="globalStatusContext.data" ng-container="body"
ng-placement="top" ng-trigger="click hover" ng-popover-class="global-status-chart">
<span class="realtime-speed">

View file

@ -46,6 +46,7 @@
}
$scope.globalStatusContext = {
isEnabled: ariaNgSettingService.getGlobalStatRefreshInterval() > 0,
data: ariaNgMonitorService.getGlobalStatsData()
};

View file

@ -127,6 +127,7 @@
$scope.context = {
currentTab: 'overview',
isEnableSpeedChart: ariaNgSettingService.getDownloadTaskRefreshInterval() > 0,
showChooseFilesToolbar: false,
btPeers: [],
healthPercent: 0,

View file

@ -146,7 +146,7 @@
ng-repeat="serverAddress in task.bittorrent.announceList | limitTo: (context.collapseTrackers ? 1 : task.bittorrent.announceList.length)"></div>
</div>
</div>
<div class="row no-hover no-background" ng-if="task && task.status == 'active'">
<div class="row no-hover no-background" ng-if="context.isEnableSpeedChart && task && task.status == 'active'">
<div class="col-sm-12">
<div class="task-status-chart-wrapper">
<ng-chart ng-data="context.statusData" height="200"></ng-chart>