diff --git a/paas2/VERSION b/paas2/VERSION index d1cbcd8b6..a5322860d 100644 --- a/paas2/VERSION +++ b/paas2/VERSION @@ -1 +1 @@ -2.14.41 +2.14.42 diff --git a/paas2/paas/saas/manager.py b/paas2/paas/saas/manager.py index 3e71560a7..7395f5159 100644 --- a/paas2/paas/saas/manager.py +++ b/paas2/paas/saas/manager.py @@ -67,7 +67,7 @@ def get_queryset(self): class SaaSVersionManager(models.Manager): - def get_version_list(self, saas_app, limit=10): + def get_version_list(self, saas_app, limit=20): if not saas_app: return [] @@ -76,8 +76,11 @@ def get_version_list(self, saas_app, limit=10): try: saas_versions = sorted(saas_versions, key=lambda s: list(map(int, s.version.split("."))), reverse=True) except Exception: - logger.exception("there got one wrong version in the saas list") - saas_versions = sorted(saas_versions, key=lambda s: s.version, reverse=True) + # logger.exception("there got one wrong version in the saas list") + try: + saas_versions = sorted(saas_versions, key=lambda s: s.upload_file.uploaded_at, reverse=True) + except Exception: + saas_versions = sorted(saas_versions, key=lambda s: s.version, reverse=True) # then limit saas_versions = saas_versions[:limit] diff --git a/paas2/release.md b/paas2/release.md index 74627d023..a7153b279 100644 --- a/paas2/release.md +++ b/paas2/release.md @@ -1,5 +1,8 @@ Release Log =============================== +# 2.14.42 + - update: saas version list sort by upload time + # 2.14.41 - update: esb update data, monitor_v3, iam confapis