mirror of
https://github.com/ansible/awx.git
synced 2026-01-13 02:50:02 -03:30
fix instance group percentage
This commit is contained in:
parent
a6e6298575
commit
32920739ef
@ -23,10 +23,10 @@ export default ['templateUrl', 'ComponentsStrings',
|
||||
scope.$watch('capacity', function() {
|
||||
if (scope.totalCapacity !== 0) {
|
||||
scope.CapacityStyle = {
|
||||
'flex-grow': scope.capacity * 0.01
|
||||
'flex-grow': scope.capacity / scope.totalCapacity * 0.01
|
||||
};
|
||||
|
||||
scope.consumedCapacity = `${scope.capacity}%`;
|
||||
scope.consumedCapacity = `${Math.round(scope.capacity / scope.totalCapacity * 10) / 10}%`;
|
||||
} else {
|
||||
scope.CapacityStyle = {
|
||||
'flex-grow': 1
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user