gui: ceph: fix version comparison

'>' on strings is not numeric, so we use our compare_ceph_versions helper

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
This commit is contained in:
Dominik Csapak 2019-05-31 12:15:53 +02:00 committed by Thomas Lamprecht
parent c0c2e40161
commit 4f71a0ff0a
2 changed files with 2 additions and 2 deletions

View File

@ -59,7 +59,7 @@ Ext.define('PVE.ceph.Services', {
var services = ['mon','mgr','mds'];
var maxversion = "00.0.00";
Object.values(metadata.version || {}).forEach(function(version) {
if (version > maxversion) {
if (PVE.Utils.compare_ceph_versions(version, maxversion) > 0) {
maxversion = version;
}
});

View File

@ -193,7 +193,7 @@ Ext.define('PVE.ceph.StatusDetail', {
var maxversion = "00.0.00";
Object.values(metadata.version || {}).forEach(function(version) {
if (version > maxversion) {
if (PVE.Utils.compare_ceph_versions(version, maxversion) > 0) {
maxversion = version;
}
});